Re: [PATCH] t/lib-gpg: adjust permissions for gnupg 2.1
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Dec 2, 2014, 23:57 UTC
- Message-ID
- <xmqqiohtli4h.fsf@gitster.dls.corp.google.com>
- In-Reply-To
- <20141202210753.GD23461@peff.net>
Jeff King <peff@peff.net> writes:
> Taking a step back, though, I am not sure I understand the reasoning > behind the original e7f224f. The rationale in the commit message is that > we want to make sure that the files are writable. But why would they not > be? They are created by "cp -R",...
Wait. After doing this,
$ mkdir -p src/a && >src/b 2>src/a/c && chmod a-w src/b src/a/c
$ cp -R src dst
$ ls -lR dstdst/b and dst/a/c are 0440 (with umask 0027, which makes src/b and src/a/c also 0440, which is copied with "cp -R").
I was primarily worried about t/lib-gpg/* being read-only from a src-tarball extract when we had a discussion that led to e7f224f7 (t/lib-gpg: make gpghome files writable, 2014-10-24).