Re: [PATCH v2] Do not show "diff --git" metainfo with --no-prefix
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Jan 18, 2008, 08:22 UTC
- Message-ID
- <7v63xrilvx.fsf@gitster.siamese.dyndns.org>
- In-Reply-To
- <7v1w8hploy.fsf@gitster.siamese.dyndns.org>
Junio C Hamano <gitster@pobox.com> writes:
Show 25 quoted lines
> Linus Torvalds <torvalds@linux-foundation.org> writes: > >> That's why tying "--git" together with any prefix handling is wrong: >> because it's a totally different issue. It's true that "git-apply" right >> now doesn't understand these things, but assuming we want to teach >> git-apply to apply to subprojects eventually (we do, don't we?) we'll >> eventually have to teach it. > > That's all correct but > > * currently diff does not recurse, nor apply does not apply > recursively; > > * "git diff" that comes with 1.5.4, if we do not do anything, > can produce a diff that will be rejected by the stricter > check "git apply" has when used with --no-prefix and friends; > > * submodule aware versions of "git diff" can be told to add > "--mark-as-git-diff" when it passes "--src-prefix=a/git-gui" > and "--dst-prefix=b/git-gui" when it recurses internally, to > defeat what my proposed patch does. > > So I think it makes more sense to mark output as a non-git diff > when custom prefix is used in the version we are going to ship > as part of 1.5.4.
Do you still have objections to the patch?
I do not think it matters _too much_, but I think starting stricter and then making things more relaxed later is easier than the other way around.