[PATCH] completion: add support for 'git blame'
Signed-off-by: Namhyung Kim <namhyung@gmail.com>
---
contrib/completion/git-completion.bash | 22 ++++++++++++++++++++++
1 files changed, 22 insertions(+), 0 deletions(-)
diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash
index 5a83090..bebadda 100755
--- a/contrib/completion/git-completion.bash
+++ b/contrib/completion/git-completion.bash
@@ -1118,6 +1118,28 @@ _git_bisect ()
esac
}
+_git_blame ()
+{
+ __git_has_doubledash && return
+
+ case "$cur" in
+ --date=*)
+ __gitcomp "$__git_log_date_formats" "" "${cur##--date=}"
+ ;;
+ --*)
+ __gitcomp "
+ --incremental --root --show-stats --score-debug
+ --show-name --show-number --porcelain
+ --line-porcelain --show-email --contents
+ --abbrev= --date= --encoding --reverse
+ "
+ ;;
+ *)
+ COMPREPLY=()
+ ;;
+ esac
+}
+
_git_branch ()
{
local i c=1 only_local_ref="n" has_r="n"
--
1.7.6