1
0
mirror of https://github.com/go-task/task.git synced 2025-01-12 04:34:11 +02:00

Merge pull request #803 from carlsmedstad/zsh-completion

Fix Zsh completion for tasks without description
This commit is contained in:
Andrey Nering 2022-07-16 21:38:50 -03:00 committed by GitHub
commit 110d1d7245
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -27,7 +27,7 @@ function __task_list() {
(( enabled )) || return 0
scripts=()
for item in "${(@)${(f)$("${cmd[@]}" --list)}[2,-1]#\* }"; do
for item in "${(@)${(f)$("${cmd[@]}" --list-all)}[2,-1]#\* }"; do
task="${item%%:[[:space:]]*}"
desc="${item##[^[:space:]]##[[:space:]]##}"
scripts+=( "${task//:/\\:}:$desc" )