Mercurial > hg
view tests/test-diff-copy-depth.t @ 29858:33461139c31c
grep: add formatter support
Several fields are renamed to be consistent with the annotate command, which
doesn't mean the last call for the name unification [1]. Actually, I'd rather
rename line_number to linenumber, linenum, lineno or line, but I want to
port the grep command to formatter first.
[1]: https://www.mercurial-scm.org/wiki/GenericTemplatingPlan#Dictionary
I don't have any better name for the list of matched/unmatched texts, so
they are just called as "texts".
author | Yuya Nishihara <yuya@tcha.org> |
---|---|
date | Thu, 18 Aug 2016 15:13:56 +0900 |
parents | bca69641de61 |
children |
line wrap: on
line source
$ for i in aaa zzz; do > hg init t > cd t > > echo > echo "-- With $i" > > touch file > hg add file > hg ci -m "Add" > > hg cp file $i > hg ci -m "a -> $i" > > hg cp $i other-file > echo "different" >> $i > hg ci -m "$i -> other-file" > > hg cp other-file somename > > echo "Status": > hg st -C > echo > echo "Diff:" > hg diff -g > > cd .. > rm -rf t > done -- With aaa Status: A somename other-file Diff: diff --git a/other-file b/somename copy from other-file copy to somename -- With zzz Status: A somename other-file Diff: diff --git a/other-file b/somename copy from other-file copy to somename