Re: [PATCH] git-archive: recursive prefix directory creation

2 messages, 2 authors, 2016-06-15 · open the first message on its own page

Re: [PATCH] git-archive: recursive prefix directory creation

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:43:11

René Scharfe [off-list ref] writes:
Junio C Hamano schrieb:
quoted
René Scharfe [off-list ref] writes:
quoted
Currently git-archive only adds a single directory entry for prefixes,
e.g. for --prefix=a/b/c/ only the directory a/b/c/ would be added to
the archive, not a/ nor a/b/.  While tar and unzip don't seem to have
a problem handling these missing entries, their omission was not
intended.
Until we start tracking directories (we briefly discussed, and I
think I agree with Linus that it should not be too painful), I'd
rather keep the current behaviour which I feel is more
consistent with what we really are doing.
Hmm, fair enough.  I started out with a simple cleanup and then I guess
went a bit overboard with that overblown path walker. :-]
Well, I take that back -- I did not realize you were primarily
talking about the LEADING part of the path.

Re: [PATCH] git-archive: recursive prefix directory creation

From: René Scharfe <hidden>
Date: 2016-06-15 22:43:11

Junio C Hamano schrieb:
René Scharfe [off-list ref] writes:
quoted
Junio C Hamano schrieb:
quoted
René Scharfe [off-list ref] writes:
quoted
Currently git-archive only adds a single directory entry for
prefixes, e.g. for --prefix=a/b/c/ only the directory a/b/c/
would be added to the archive, not a/ nor a/b/.  While tar and
unzip don't seem to have a problem handling these missing
entries, their omission was not intended.
Until we start tracking directories (we briefly discussed, and I 
think I agree with Linus that it should not be too painful), I'd 
rather keep the current behaviour which I feel is more consistent
with what we really are doing.
Hmm, fair enough.  I started out with a simple cleanup and then I
guess went a bit overboard with that overblown path walker. :-]
Well, I take that back -- I did not realize you were primarily 
talking about the LEADING part of the path.
In any case, please don't apply this patch.  I checked again, and it
turns out both tar and zip don't always add leading directories to
archives.  So my "cleanup" only adds bloat.  I'll try to find another
way to beautify the code.

René
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help