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

git archive: tar.umask ignored

From
JMJacek Masiulaniec <jacekm@dobremiasto.net>
Date
Apr 12, 2011, 09:39 UTC
Message-ID
<BANLkTimTs+Qh9fNs6pLcZidYy-YjXNR2iw@mail.gmail.com>
Hello git@,

I believe git has an issue with command line override of configuration options. Notice how in both cases below the file mode is 775 despite tar.umask difference:

[jacekm@localhost git]$ ./git --version
git version 1.7.4.4
[jacekm@localhost git]$ ./git archive --remote=/repo/website.git HEAD
| tar -tvf - | head -1
drwxrwxr-x root/root         0 2011-04-11 13:47:09 bin/
[jacekm@localhost git]$ ./git -c tar.umask=0022 archive
--remote=/repo/website.git HEAD | tar -tvf - | head -1
drwxrwxr-x root/root         0 2011-04-11 13:47:09 bin/
[jacekm@localhost git]$

In contrast, tweaking tar.umask in ~/.gitconfig does have the desired impact on the file mode.

Jacek
Next: René Scharfe
Message 1 of 6 in “git archive: tar.umask ignored”
  1. Jacek MasiulaniecApr 12, 2011
  2. René ScharfeApr 12, 2011
  3. René ScharfeApr 12, 2011
  4. Jacek MasiulaniecApr 12, 2011
  5. René ScharfeApr 14, 2011
  6. Junio C HamanoApr 14, 2011

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.