# [PATCH 8/8] bash completion: Add completion for 'git mv'

1 messages from 2008-08-05 to 2008-08-05. Participants: Shawn O. Pearce.
Thread: https://gitlist.dev/t/14845

## Shawn O. Pearce, 2008-08-05 19:08

Subject: [PATCH 8/8] bash completion: Add completion for 'git mv'
Message-ID: <20080805190830.GD27207@spearce.org>
URL: https://gitlist.dev/e/20080805190830.GD27207%40spearce.org

```
The missing patch 8.

-- 
Shawn.


Added completions for all long options specified in the docs
        --dry-run

Signed-off-by: Lee Marlow <lee.marlow@gmail.com>
---
 contrib/completion/git-completion.bash |   13 +++++++++++++
 1 files changed, 13 insertions(+), 0 deletions(-)

diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash
index 936cd35..57b8c0f 100755
--- a/contrib/completion/git-completion.bash
+++ b/contrib/completion/git-completion.bash
@@ -983,6 +983,18 @@ _git_merge_base ()
 	__gitcomp "$(__git_refs)"
 }
 
+_git_mv ()
+{
+	local cur="${COMP_WORDS[COMP_CWORD]}"
+	case "$cur" in
+	--*)
+		__gitcomp "--dry-run"
+		return
+		;;
+	esac
+	COMPREPLY=()
+}
+
 _git_name_rev ()
 {
 	__gitcomp "--tags --all --stdin"
@@ -1615,6 +1627,7 @@ _git ()
 	ls-tree)     _git_ls_tree ;;
 	merge)       _git_merge;;
 	merge-base)  _git_merge_base ;;
+	mv)          _git_mv ;;
 	name-rev)    _git_name_rev ;;
 	pull)        _git_pull ;;
 	push)        _git_push ;;
-- 
1.6.0.rc1.48.g2b6032


```
