mirror of
https://github.com/fish-shell/fish-shell
synced 2025-01-13 21:44:16 +00:00
Fix minor bug in completions for make, which caused it to fail completing targets beginning with 't'
darcs-hash:20051027152332-ac50b-cb3741f7ea0c74a6885e31f78f2aa79323ae48a1.gz
This commit is contained in:
parent
b78fba810c
commit
e8d02159da
1 changed files with 7 additions and 1 deletions
|
@ -1,5 +1,11 @@
|
|||
#Completions for make
|
||||
complete -x -c make -a "(grep -h -E '^[^#%=\t$][^#%=$]*:([^=]|$)' Makefile makefile GNUmakefile | cut -d ":" -f 1 | sed -r 's/^ *//;s/ *$//;s/ +/\n/g' ^/dev/null)" -d "Target"
|
||||
|
||||
function __fish_print_make_targets
|
||||
set files Makefile makefile GNUmakefile
|
||||
grep -h -E '^[^#%=$[:space:]][^#%=$]*:([^=]|$)' $files | cut -d ":" -f 1 | sed -r 's/^ *//;s/ *$//;s/ +/\n/g' ^/dev/null
|
||||
end
|
||||
|
||||
complete -x -c make -a "(__fish_print_make_targets)" -d "Target"
|
||||
complete -r -c make -s f -d "Use file as makefile" -r
|
||||
complete -x -c make -s C -x -a "(__fish_complete_directory (commandline -ct))" -d "Change directory"
|
||||
complete -c make -s d -d "Debug"
|
||||
|
|
Loading…
Reference in a new issue