Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion misc/bash/_ghq
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,15 @@ function _ghq () {

case $cword in
1)
COMPREPLY=( $(compgen -W "get list" -- $cur) );;
COMPREPLY=( $(compgen -W "get list rm" -- $cur) );;
2)
case $prev in
get)
COMPREPLY=( $(compgen -W "$(ghq list --unique)" -- $cur) );;
list)
COMPREPLY=( $(compgen -W "$(ghq list)" -- $cur) );;
rm)
COMPREPLY=( $(compgen -W "$(ghq list)" -- $cur) );;
esac;;
*)
COMPREPLY=( $(compgen -W "$(ls)" -- $cur) );;
Expand Down
6 changes: 6 additions & 0 deletions misc/zsh/_ghq
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,12 @@ function _ghq () {
'(-)*:: :->null_state' \
&& ret=0
;;
(rm)
_arguments -C \
'--dry-run[Do not remove actually]' \
'(-)*:: :->null_state' \
&& ret=0
;;
(help|h)
__ghq_commands && ret=0
;;
Expand Down