Re: [PATCH v2 2/2] object name: introduce '^{/!-}' notation

2015-06-09 Thread Will Palmer
On Mon, Jun 8, 2015 at 5:39 PM, Junio C Hamano wrote: > Will Palmer writes: >> diff --git a/t/t1511-rev-parse-caret.sh b/t/t1511-rev-parse-caret.sh >> index e0fe102..8a5983f 100755 >> --- a/t/t1511-rev-parse-caret.sh >> +++ b/t/t1511-rev-parse-caret.sh >> @@ -19

[PATCH v2 1/2] test for '!' handling in rev-parse's named commits

2015-06-05 Thread Will Palmer
for a commit whose message contains the string "!Message". Signed-off-by: Will Palmer --- t/t1511-rev-parse-caret.sh | 23 ++- 1 file changed, 22 insertions(+), 1 deletion(-) diff --git a/t/t1511-rev-parse-caret.sh b/t/t1511-rev-parse-caret.sh index 15973f2..e0fe1

[PATCH v2 0/2] specify commit by negative pattern

2015-06-05 Thread Will Palmer
future extensions indicated things like "what was to be searched", e.g.: @^{/!(a=author)}. With only two interpretations of the '!' leader, for now (including the '!!' literal notation), adding such a verbose form, such as '@^{/!(negative)foo}', seemed inappr

[PATCH v2 2/2] object name: introduce '^{/!-}' notation

2015-06-05 Thread Will Palmer
WIP commit". That sort of thing now possible, via commands such as: $ git diff @^{/!-^WIP} The leader '/!-', rather than simply '/!', to denote a negative match, is chosen to leave room for additional modifiers in the future. Signed-off-by: Will Palmer --

Re: [PATCH 1/2] test for '!' handling in rev-parse's named commits

2015-06-03 Thread Will Palmer
On Wed, Jun 3, 2015 at 10:52 PM, Junio C Hamano wrote: > The /! sequence being reserved does not mean it was planned to be > used only for a single thing in the future, though. > > (snip) > > cf. http://thread.gmane.org/gmane.comp.version-control.git/40460/focus=40477 > Thank you for that additio

[PATCH 1/2] test for '!' handling in rev-parse's named commits

2015-06-03 Thread Will Palmer
rch for a commit whose message contains the string "!Message". Signed-off-by: Will Palmer --- t/t1511-rev-parse-caret.sh | 19 ++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/t/t1511-rev-parse-caret.sh b/t/t1511-rev-parse-caret.sh index 15973f2..0c46e5c

[PATCH 0/2] specify commit by negative pattern

2015-06-03 Thread Will Palmer
ht of as potentially useful someday, but didn't fit well with the original patch's limitations (namely: always searching across all refs). Will Palmer (2): test for '!' handling in rev-parse's named commits object name: introduce '^{/!}' notation Documentat

[PATCH 2/2] object name: introduce '^{/!}' notation

2015-06-03 Thread Will Palmer
y, the "special case" for the empty pattern has been extended to handle the empty negative pattern - which never matches, to continue to ensure that an empty pattern never reaches the real regexp code, as per notes in 4322842 "get_sha1: handle special case $commit^{/}"