diff --git a/etc/bash_completion.sh b/etc/bash_completion.sh index d48cdb3..06fd02e 100644 --- a/etc/bash_completion.sh +++ b/etc/bash_completion.sh @@ -145,11 +145,11 @@ _git_graft(){ _git_ignore(){ case "$cur" in --*) - __gitcomp "--global --local --private" + __gitcomp "--global --local --private --edit --remove" return ;; -*) - __gitcomp "--global --local --private -g -l -p" + __gitcomp "--global --local --private --edit --remove -g -l -p -e -r" return ;; esac diff --git a/etc/git-extras-completion.zsh b/etc/git-extras-completion.zsh index 9b95c58..c6aab46 100644 --- a/etc/git-extras-completion.zsh +++ b/etc/git-extras-completion.zsh @@ -317,9 +317,11 @@ _git-guilt() { _git-ignore() { _arguments -C \ - '(--local -l)'{--local,-l}'[show local gitignore]' \ - '(--global -g)'{--global,-g}'[show global gitignore]' \ - '(--private -p)'{--private,-p}'[show repo gitignore]' \ + '(--local -l)'{--local,-l}'[set context to local gitignore]' \ + '(--global -g)'{--global,-g}'[set context to global gitignore]' \ + '(--private -p)'{--private,-p}'[set context to private gitignore]' \ + '(--edit -e)'{--edit,-e}'[set action to edit]' \ + '(--remove -r)'{--remove,-r}'[set action to remove]' \ '*:filename:_files' } @@ -443,7 +445,7 @@ zstyle ':completion:*:*:git:*' user-commands $existing_user_commands \ graft:'merge and destroy a given branch' \ guilt:'calculate change between two revisions' \ ignore-io:'get sample gitignore file' \ - ignore:'add .gitignore patterns' \ + ignore:'Modify or display .gitignore files' \ info:'returns information on current repository' \ local-commits:'list local commits' \ lock:'lock a file excluded from version control' \ diff --git a/etc/git-extras.fish b/etc/git-extras.fish index 976cfca..5104b27 100644 --- a/etc/git-extras.fish +++ b/etc/git-extras.fish @@ -32,7 +32,7 @@ set __fish_git_extras_commands \ "graft:Merge and destroy a given branch" \ "guilt:calculate change between two revisions" \ "ignore-io:Get sample gitignore file" \ - "ignore:Add .gitignore patterns" \ + "ignore:Modify or display .gitignore files" \ "info:Returns information on current repository" \ "local-commits:List local commits" \ "lock:Lock a file excluded from version control" \ @@ -162,9 +162,11 @@ complete -c git -f -n '__fish_git_using_command guilt' -s e -l email -d 'display complete -c git -f -n '__fish_git_using_command guilt' -s d -l debug -d 'output debug information' complete -c git -f -n '__fish_git_using_command guilt' -s h -d 'output usage information' # ignore -complete -c git -f -n '__fish_git_using_command ignore' -s l -l local -d 'show local gitignore' -complete -c git -f -n '__fish_git_using_command ignore' -s g -l global -d 'show global gitignore' -complete -c git -f -n '__fish_git_using_command ignore' -s p -l private -d 'show repo gitignore' +complete -c git -f -n '__fish_git_using_command ignore' -s l -l local -d 'set context to local gitignore' +complete -c git -f -n '__fish_git_using_command ignore' -s g -l global -d 'set context to global gitignore' +complete -c git -f -n '__fish_git_using_command ignore' -s p -l private -d 'set context to private gitignore' +complete -c git -f -n '__fish_git_using_command ignore' -s e -l edit -d 'set action to edit' +complete -c git -f -n '__fish_git_using_command ignore' -s r -l remove -d 'set action to remove' # ignore-io function __fish_git_extra_get_ignore_io_types # we will first remove every tab spaces, and then append `\t` at the end to remove the default description