From: Anton Vorontsov <avorontsov@ru.mvista.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: Scott Wood <scottwood@freescale.com>,
git@vger.kernel.org, linuxppc-dev@ozlabs.org
Subject: Re: git apply vs. renamed files index mismatch
Date: Tue, 9 Sep 2008 19:14:46 +0400 [thread overview]
Message-ID: <20080909151446.GA10395@oksana.dev.rtsoft.ru> (raw)
In-Reply-To: <7vtzcp8jk0.fsf@gitster.siamese.dyndns.org>
On Tue, Sep 09, 2008 at 07:45:19AM -0700, Junio C Hamano wrote:
> Anton Vorontsov <avorontsov@ru.mvista.com> writes:
>
> > Now consider the following patch (modified by hand: it should say
> > +foo, but I changed it to +bar).
> > ...
> > The "index ..." stuff says that there are no changes and it is
> > pure rename, but obviously there is a change.
>
> Ah, I see what you mean. But in general, it is not obvious at all.
>
> If you have the identical preimage (recorded on the LHS of the index line)
> or the patch reproduces the postimage in full (i.e. "create a new file"),
> you *could* notice. It's an interesting idea from git person's point of
> view (i.e. "would be fun to implement"), but I doubt it would be useful in
> practice, because:
>
> (1) You often do not have the identically matching preimage;
>
> (2) More importantly, it is not unusual for people to *edit* the patch in
> their MUA (think of typofixes), after getting it out of git.
Not for rename patches...
> (3) Even more importantly, even if you notice there is some difference,
Just noticing that there is a difference is enough.
As for implementing, isn't this as simple as this pseudo code:
if (index_deleted_file == index_new_file)
if (deleted_file != new_file)
printk("warning\n");
In the git-apply?
--
Anton Vorontsov
email: cbouatmailru@gmail.com
irc://irc.freenode.net/bd2
WARNING: multiple messages have this Message-ID (diff)
From: Anton Vorontsov <avorontsov@ru.mvista.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: Scott Wood <scottwood@freescale.com>,
Becky Bruce <becky.bruce@freescale.com>,
linuxppc-dev@ozlabs.org, git@vger.kernel.org
Subject: Re: git apply vs. renamed files index mismatch
Date: Tue, 9 Sep 2008 19:14:46 +0400 [thread overview]
Message-ID: <20080909151446.GA10395@oksana.dev.rtsoft.ru> (raw)
In-Reply-To: <7vtzcp8jk0.fsf@gitster.siamese.dyndns.org>
On Tue, Sep 09, 2008 at 07:45:19AM -0700, Junio C Hamano wrote:
> Anton Vorontsov <avorontsov@ru.mvista.com> writes:
>
> > Now consider the following patch (modified by hand: it should say
> > +foo, but I changed it to +bar).
> > ...
> > The "index ..." stuff says that there are no changes and it is
> > pure rename, but obviously there is a change.
>
> Ah, I see what you mean. But in general, it is not obvious at all.
>
> If you have the identical preimage (recorded on the LHS of the index line)
> or the patch reproduces the postimage in full (i.e. "create a new file"),
> you *could* notice. It's an interesting idea from git person's point of
> view (i.e. "would be fun to implement"), but I doubt it would be useful in
> practice, because:
>
> (1) You often do not have the identically matching preimage;
>
> (2) More importantly, it is not unusual for people to *edit* the patch in
> their MUA (think of typofixes), after getting it out of git.
Not for rename patches...
> (3) Even more importantly, even if you notice there is some difference,
Just noticing that there is a difference is enough.
As for implementing, isn't this as simple as this pseudo code:
if (index_deleted_file == index_new_file)
if (deleted_file != new_file)
printk("warning\n");
In the git-apply?
--
Anton Vorontsov
email: cbouatmailru@gmail.com
irc://irc.freenode.net/bd2
next prev parent reply other threads:[~2008-09-09 15:14 UTC|newest]
Thread overview: 50+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-09-08 19:09 [PATCH 0/4] POWERPC: 32/64-bit DMA code merge and cleanup Becky Bruce
2008-09-08 19:09 ` [PATCH 1/4] POWERPC: Rename dma_64.c to dma.c Becky Bruce
2008-09-08 19:09 ` [PATCH 2/4] POWERPC: Move iommu dma ops from dma.c to dma-iommu.c Becky Bruce
2008-09-08 19:09 ` [PATCH 3/4] POWERPC: Drop archdata numa_node Becky Bruce
2008-09-08 19:09 ` [PATCH 4/4] POWERPC: Merge 32 and 64-bit dma code Becky Bruce
2008-09-08 22:03 ` Christoph Hellwig
2008-09-09 10:54 ` Benjamin Herrenschmidt
2008-09-09 14:39 ` Becky Bruce
2008-09-09 20:45 ` Christoph Hellwig
2008-09-09 22:10 ` Benjamin Herrenschmidt
2008-09-09 22:13 ` Christoph Hellwig
2008-09-09 22:17 ` Becky Bruce
2008-09-12 20:34 ` [PATCH V2 " Becky Bruce
2008-10-13 14:49 ` Josh Boyer
2008-10-13 15:41 ` Josh Boyer
2008-10-13 18:06 ` Kumar Gala
2008-10-13 18:21 ` Josh Boyer
2008-10-13 18:22 ` Kumar Gala
2008-10-13 23:30 ` Benjamin Herrenschmidt
2008-10-14 1:52 ` Kumar Gala
2008-10-14 10:24 ` Josh Boyer
2008-10-14 12:05 ` Benjamin Herrenschmidt
2008-10-14 15:45 ` Becky Bruce
2008-10-13 23:30 ` Benjamin Herrenschmidt
2008-09-08 21:57 ` [PATCH 2/4] POWERPC: Move iommu dma ops from dma.c to dma-iommu.c Christoph Hellwig
2008-09-12 15:32 ` Becky Bruce
2008-09-08 19:18 ` [PATCH 1/4] POWERPC: Rename dma_64.c to dma.c Scott Wood
2008-09-08 21:27 ` git apply vs. renamed files index mismatch (was: Re: [PATCH 1/4] POWERPC: Rename dma_64.c to dma.c) Anton Vorontsov
2008-09-08 21:27 ` Anton Vorontsov
2008-09-08 21:38 ` git apply vs. renamed files index mismatch Scott Wood
2008-09-08 21:38 ` Scott Wood
2008-09-08 21:54 ` Anton Vorontsov
2008-09-08 21:54 ` Anton Vorontsov
2008-09-09 0:55 ` Junio C Hamano
2008-09-09 0:55 ` Junio C Hamano
2008-09-09 9:06 ` Geert Uytterhoeven
2008-09-09 9:06 ` Geert Uytterhoeven
2008-09-08 21:58 ` git apply vs. renamed files index mismatch (was: Re: [PATCH 1/4] POWERPC: Rename dma_64.c to dma.c) Christoph Hellwig
2008-09-08 21:58 ` Christoph Hellwig
2008-09-09 0:53 ` git apply vs. renamed files index mismatch Junio C Hamano
2008-09-09 0:53 ` Junio C Hamano
2008-09-09 10:06 ` Anton Vorontsov
2008-09-09 10:06 ` Anton Vorontsov
2008-09-09 14:45 ` Junio C Hamano
2008-09-09 14:45 ` Junio C Hamano
2008-09-09 15:14 ` Anton Vorontsov [this message]
2008-09-09 15:14 ` Anton Vorontsov
2008-09-10 3:31 ` Junio C Hamano
2008-09-10 3:31 ` Junio C Hamano
2008-09-08 21:56 ` [PATCH 0/4] POWERPC: 32/64-bit DMA code merge and cleanup Christoph Hellwig
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20080909151446.GA10395@oksana.dev.rtsoft.ru \
--to=avorontsov@ru.mvista.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=linuxppc-dev@ozlabs.org \
--cc=scottwood@freescale.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.