* [RFC] Teach diff to imply --find-copies-harder upon -C -C
@ 2007-06-11 20:12 Johannes Schindelin
2007-06-11 23:05 ` Brian Gernhardt
2007-06-12 5:05 ` Junio C Hamano
0 siblings, 2 replies; 3+ messages in thread
From: Johannes Schindelin @ 2007-06-11 20:12 UTC (permalink / raw)
To: git
earlier, a second "-C" on the command line had no effect. But since I use
"--find-copies-harder" quite a bit, and it is so long to type, and I am
an inherently lazy person, I'd like the second "-C" to be a shortcut for
"--find-copies-harder".
Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de>
---
diff.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/diff.c b/diff.c
index 1d234d3..4aa9bbc 100644
--- a/diff.c
+++ b/diff.c
@@ -2201,6 +2201,8 @@ int diff_opt_parse(struct diff_options *options, const char **av, int ac)
options->detect_rename = DIFF_DETECT_RENAME;
}
else if (!prefixcmp(arg, "-C")) {
+ if (options->detect_rename == DIFF_DETECT_COPY)
+ options->find_copies_harder = 1;
if ((options->rename_score =
diff_scoreopt_parse(arg)) == -1)
return -1;
^ permalink raw reply related [flat|nested] 3+ messages in thread* Re: [RFC] Teach diff to imply --find-copies-harder upon -C -C
2007-06-11 20:12 [RFC] Teach diff to imply --find-copies-harder upon -C -C Johannes Schindelin
@ 2007-06-11 23:05 ` Brian Gernhardt
2007-06-12 5:05 ` Junio C Hamano
1 sibling, 0 replies; 3+ messages in thread
From: Brian Gernhardt @ 2007-06-11 23:05 UTC (permalink / raw)
To: Johannes Schindelin; +Cc: git
On Jun 11, 2007, at 4:12 PM, Johannes Schindelin wrote:
>
> earlier, a second "-C" on the command line had no effect. But since
> I use
> "--find-copies-harder" quite a bit, and it is so long to type, and
> I am
> an inherently lazy person, I'd like the second "-C" to be a
> shortcut for
> "--find-copies-harder".
I like it. "git-diff -C -C ..." reads "git-diff, find copies. No
really, find copies."
~~ Brian
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [RFC] Teach diff to imply --find-copies-harder upon -C -C
2007-06-11 20:12 [RFC] Teach diff to imply --find-copies-harder upon -C -C Johannes Schindelin
2007-06-11 23:05 ` Brian Gernhardt
@ 2007-06-12 5:05 ` Junio C Hamano
1 sibling, 0 replies; 3+ messages in thread
From: Junio C Hamano @ 2007-06-12 5:05 UTC (permalink / raw)
To: Johannes Schindelin; +Cc: git
Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:
> earlier, a second "-C" on the command line had no effect. But since I use
> "--find-copies-harder" quite a bit, and it is so long to type, and I am
> an inherently lazy person, I'd like the second "-C" to be a shortcut for
> "--find-copies-harder".
Sounds good and consistent with what we do in git-blame.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2007-06-12 5:05 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-06-11 20:12 [RFC] Teach diff to imply --find-copies-harder upon -C -C Johannes Schindelin
2007-06-11 23:05 ` Brian Gernhardt
2007-06-12 5:05 ` Junio C Hamano
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox