git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH 2/2] update-server-info: create info/* with mode 0666

From
Junio C Hamano <gitster@pobox.com>
Date
Jan 6, 2015, 21:43 UTC
Message-ID
<xmqqegr7oa9m.fsf@gitster.dls.corp.google.com>
In-Reply-To
<20150106193950.GB28440@peff.net>
Jeff King <peff@peff.net> writes:
Show 23 quoted lines
> On Tue, Jan 06, 2015 at 10:47:01AM -0800, Junio C Hamano wrote:
>
>> Jeff King <peff@peff.net> writes:
>> 
>> > +test_expect_success POSIXPERM 'info/refs is readable in unshared repo' '
>> > +	rm -f .git/info/refs &&
>> > +	test_unconfig core.sharedrepository &&
>> > +	umask 002 &&
>> > +	git update-server-info &&
>> > +	echo "-rw-rw-r--" >expect &&
>> > +	modebits .git/info/refs >actual &&
>> > +	test_cmp expect actual
>> > +'
>> 
>> Hmm, the label and the test look somewhat out-of-sync.  "readable as
>> long as umask allows it" would be more in line with what the fix is
>> about (i.e. I would expect a test with that title to pass even if I
>> changed 'umask 002' to 'umask 007', but that is not what we want in
>> this series).
>
> That is definitely not what the series means to accomplish. I think
> naming the test "info/refs respects umask in unshared repo" is probably
> a better title for the test.

Thanks for sanity-checking me (I am still somewhat feverish and not performing at 100% level). Here is what I have locally (but haven't got around to today's integration cycle yet) on top.

Subject: [PATCH] SQUASH???
---
 t/t1301-shared-repo.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/t/t1301-shared-repo.sh b/t/t1301-shared-repo.sh
index feff55e..d5eacb0 100755
--- a/t/t1301-shared-repo.sh
+++ b/t/t1301-shared-repo.sh
@@ -111,7 +111,7 @@ do
 
 done
 
-test_expect_success POSIXPERM 'info/refs is readable in unshared repo' '
+test_expect_success POSIXPERM 'info/refs is created honoring the umask' '
 	rm -f .git/info/refs &&
 	test_unconfig core.sharedrepository &&
 	umask 002 &&
-- 
2.2.1-349-g24d7964
Previous: Jeff KingNext: Jeff King
Message 8 of 14 in “git 2.2.x: Unexpected, overstrict file permissions after "git update-server-info"”
  1. Paul SokolovskyJan 5, 2015
  2. Torsten BögershausenJan 5, 2015
  3. Jeff KingJan 6, 2015
  4. 1/2 t1301: set umask in reflog sharedrepository=group testJeff King, Jan 6, 2015
  5. 2/2 update-server-info: create info/* with mode 0666Jeff King, Jan 6, 2015
  6. Junio C HamanoJan 6, 2015
  7. Jeff KingJan 6, 2015
  8. Junio C HamanoJan 6, 2015
  9. Jeff KingJan 6, 2015
  10. Junio C HamanoJan 6, 2015
  11. Paul SokolovskyJan 6, 2015
  12. Junio C HamanoJan 6, 2015
  13. Jeff KingJan 6, 2015
  14. Paul SokolovskyJan 6, 2015

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.