X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ian/git?a=blobdiff_plain;f=contrib%2Ftg-completion.bash;h=0ee233c4781b1fe8d3a84772c59373e30ed2f06f;hb=5e39d846c5768b2be709a51757222501e54aaacb;hp=9641d04dea15bbf019fe492417b1aa617b26abe7;hpb=8c77c342166ddc6ecb3840628d89ddc5bb6b043b;p=topgit.git diff --git a/contrib/tg-completion.bash b/contrib/tg-completion.bash index 9641d04..0ee233c 100755 --- a/contrib/tg-completion.bash +++ b/contrib/tg-completion.bash @@ -359,6 +359,35 @@ _tg_patch () local cur="${COMP_WORDS[COMP_CWORD]}" case "$cur" in + -*) + __tgcomp " + -i + -w + " + ;; + *) + __tgcomp "$(__tg_topics)" + esac +} + +_tg_push () +{ + local cur="${COMP_WORDS[COMP_CWORD]}" + + __tg_complete_arg "-r" && { + __tgcomp "$(__tg_remotes)" + return + } + + case "$cur" in + -*) + __tgcomp " + --no-deps + --dry-run + --tgish-only + -r + " + ;; *) __tgcomp "$(__tg_topics)" esac @@ -443,6 +472,7 @@ _tg () info) _tg_info ;; mail) _tg_mail ;; patch) _tg_patch ;; + push) _tg_push ;; remote) _tg_remote ;; summary) _tg_summary ;; update) _tg_update ;;