mirror of
https://github.com/go-task/task.git
synced 2024-12-12 10:45:49 +02:00
Fix broken completion when no taskfile is found
This commit is contained in:
parent
b65935d6cf
commit
95fc26d4ad
@ -1,5 +1,8 @@
|
|||||||
function __task_get_tasks --description "Prints all available tasks with their description"
|
function __task_get_tasks --description "Prints all available tasks with their description"
|
||||||
task -l | sed '1d' | awk '{ $1=""; print $0 }' | sed 's/:\ /\t/g' | string trim
|
set -l output (task -l 2>&1 < /dev/null | sed '1d' | awk '{ $1=""; print $0 }' | sed 's/:\ /\t/g' | string trim | string split0)
|
||||||
|
if test $output
|
||||||
|
echo $output
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
complete -c task -d 'Runs the specified task(s). Falls back to the "default" task if no task name was specified, or lists all tasks if an unknown task name was
|
complete -c task -d 'Runs the specified task(s). Falls back to the "default" task if no task name was specified, or lists all tasks if an unknown task name was
|
||||||
|
Loading…
Reference in New Issue
Block a user