summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 983591c)
raw | patch | inline | side by side (parent: 983591c)
author | Shawn O. Pearce <spearce@spearce.org> | |
Mon, 5 Feb 2007 20:44:28 +0000 (15:44 -0500) | ||
committer | Junio C Hamano <junkio@cox.net> | |
Mon, 5 Feb 2007 21:49:00 +0000 (13:49 -0800) |
I'm lazy. I don't want to type out --prune if bash can do it for
me with --<tab>.
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
me with --<tab>.
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
contrib/completion/git-completion.bash | patch | blob | history |
index c0dae5484d75f87219b0765704c574dbbe941567..324bfbd8bbed887004b2105424dfc3f24745b784 100755 (executable)
__git_complete_revlist
}
+_git_gc ()
+{
+ local cur="${COMP_WORDS[COMP_CWORD]}"
+ case "$cur" in
+ --*)
+ __gitcomp "--prune"
+ return
+ ;;
+ esac
+ COMPREPLY=()
+}
+
_git_ls_remote ()
{
__gitcomp "$(__git_remotes)"
diff-tree) _git_diff_tree ;;
fetch) _git_fetch ;;
format-patch) _git_format_patch ;;
+ gc) _git_gc ;;
log) _git_log ;;
ls-remote) _git_ls_remote ;;
ls-tree) _git_ls_tree ;;
complete -o default -o nospace -F _git_diff_tree git-diff-tree
complete -o default -o nospace -F _git_fetch git-fetch
complete -o default -o nospace -F _git_format_patch git-format-patch
+complete -o default -o nospace -F _git_gc git-gc
complete -o default -o nospace -F _git_log git-log
complete -o default -o nospace -F _git_ls_remote git-ls-remote
complete -o default -o nospace -F _git_ls_tree git-ls-tree