Fix broken git alias completion

The previous command outputs a lot of junk, does not strip after the
white-space in OSX (10.8.2).

Tried out the new command on both Ubuntu (12.04.1) and OSX (10.8.2)
This commit is contained in:
Terje Larsen 2012-10-22 20:37:47 +02:00
parent f56f84c6ac
commit e878947cb2

View File

@ -243,4 +243,4 @@ complete -f -c git -n '__fish_git_using_command submodule' -a 'add status init u
complete -f -c git -n '__fish_git_needs_command' -a whatchanged -d 'Show logs with difference each commit introduces'
## Aliases (custom user-defined commands)
complete -c git -n '__fish_git_needs_command' -a '(git config --get-regexp alias | sed -e "s/^alias\.\(\S\+\).*/\1/")' -d 'Alias (user-defined command)'
complete -c git -n '__fish_git_needs_command' -a '(git config --get-regexp alias | sed "s/^alias\.\([^ ]*\).*/\1/")' -d 'Alias (user-defined command)'