git-completion.bash: silence "not a valid object" errors
Trying to complete the command git show master:./file would cause a "Not a valid object name" error to be output on standard error. Silence the error so it won't appear on the command line. Signed-off-by: Dylan Smith <dylan.ah.smith@gmail.com> Reviewed-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
parent
bafc478f16
commit
ca87dd623d
@ -676,7 +676,7 @@ __git_complete_revlist_file ()
|
||||
*) pfx="$ref:$pfx" ;;
|
||||
esac
|
||||
|
||||
__gitcomp_nl "$(git --git-dir="$(__gitdir)" ls-tree "$ls" \
|
||||
__gitcomp_nl "$(git --git-dir="$(__gitdir)" ls-tree "$ls" 2>/dev/null \
|
||||
| sed '/^100... blob /{
|
||||
s,^.* ,,
|
||||
s,$, ,
|
||||
|
Loading…
Reference in New Issue
Block a user