Skip to content

Commit 5269f7f

Browse files
artagnongitster
authored andcommitted
completion: show can take both revlist and paths
The 'git show' completion uses __git_complete_file (aliased to __git_complete_revlist_file), because accepts <tree-ish>:<path> as well as <commit-ish>. But the command also accepts range of commits in A..B notation, so using __git_complete_revlist_file is more appropriate. There still remain two users of __git_complete_file, completions for "archive" and "ls-tree". As these commands do not take range notation, and "git show" no longer uses __git_complete_file, the implementation of it can be updated not to complete ranges, but that is a separate topic. Signed-off-by: Ramkumar Ramachandra <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent d8517cc commit 5269f7f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

contrib/completion/git-completion.bash

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2360,7 +2360,7 @@ _git_show ()
23602360
return
23612361
;;
23622362
esac
2363-
__git_complete_file
2363+
__git_complete_revlist_file
23642364
}
23652365

23662366
_git_show_branch ()

0 commit comments

Comments
 (0)