handle_revision_arg: record modes for "a..b" endpoints
The "a..b" revision syntax was designed to handle commits, so it doesn't bother to record any mode we find while traversing a "tree:path" endpoint. These days "git diff" can diff blobs using either "a:path..b:path" (with dots) or "a:path b:path" (without), but the two behave inconsistently, as the with-dots version fails to notice the mode. Let's teach the dot-dot range parser to record modes; it doesn't cost us anything, and it makes this case work. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
committed by
Junio C Hamano
parent
74e89110a3
commit
101dd4de16
@ -71,7 +71,7 @@ test_expect_success 'index of ranged tree:path diff' '
|
||||
test_expect_failure 'ranged tree:path diff uses filenames as paths' '
|
||||
check_paths one two
|
||||
'
|
||||
test_expect_failure 'ranged tree:path diff shows mode change' '
|
||||
test_expect_success 'ranged tree:path diff shows mode change' '
|
||||
check_mode 100644 100755
|
||||
'
|
||||
|
||||
|
||||
Reference in New Issue
Block a user