diff options
author | Junio C Hamano <junkio@cox.net> | 2006-10-31 14:22:34 -0800 |
---|---|---|
committer | Junio C Hamano <junkio@cox.net> | 2006-10-31 14:22:34 -0800 |
commit | 62476c8e331a22e224d87c18830913129f5f303b (patch) | |
tree | f81057bf5002f016d26a82d055ff694f31ab2e43 /Documentation/git-rev-parse.txt | |
parent | 0d981c67d8bcf4610e165744059c1e9e14609baa (diff) | |
download | git-62476c8e331a22e224d87c18830913129f5f303b.tar.gz |
Introduce a new revision set operator <rev>^!
This is a shorthand for "<rev> --not <rev>^@", i.e. "include
this commit but exclude any of its parents".
When a new file $F is introduced by revision $R, this notation
can be used to find a copy-and-paste from existing file in the
parents of that revision without annotating the ancestry of the
lines that were copied from:
git pickaxe -f -C $R^! -- $F
Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'Documentation/git-rev-parse.txt')
-rw-r--r-- | Documentation/git-rev-parse.txt | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/Documentation/git-rev-parse.txt b/Documentation/git-rev-parse.txt index 5d4257062d..cda80b18f4 100644 --- a/Documentation/git-rev-parse.txt +++ b/Documentation/git-rev-parse.txt @@ -222,14 +222,21 @@ of `r1` and `r2` and is defined as It it the set of commits that are reachable from either one of `r1` or `r2` but not from both. -Here are a few examples: +Two other shorthands for naming a set that is formed by a commit +and its parent commits exists. `r1{caret}@` notation means all +parents of `r1`. `r1{caret}!` includes commit `r1` but excludes +its all parents. + +Here are a handful examples: D A B D D F A B C D F - ^A G B D + ^A G B D ^A F B C F G...I C D F G I - ^B G I C D F G I + ^B G I C D F G I + F^@ A B C + F^! H D F H Author ------ |