sequencer: refactor transform_todos() to work on a todo_list
[gitweb.git] / contrib / completion / git-completion.zsh
index c3521fbfc44fd8db18244bc10d346ee39b1c3c90..049d6b80f650717f20e68568251c21098f598d80 100644 (file)
@@ -39,7 +39,7 @@ if [ -z "$script" ]; then
                test -f $e && script="$e" && break
        done
 fi
-ZSH_VERSION='' . "$script"
+GIT_SOURCING_ZSH_COMPLETION=y . "$script"
 
 __gitcomp ()
 {
@@ -93,6 +93,15 @@ __gitcomp_nl_append ()
        compadd -Q -S "${4- }" -p "${2-}" -- ${=1} && _ret=0
 }
 
+__gitcomp_file_direct ()
+{
+       emulate -L zsh
+
+       local IFS=$'\n'
+       compset -P '*[=:]'
+       compadd -Q -f -- ${=1} && _ret=0
+}
+
 __gitcomp_file ()
 {
        emulate -L zsh