_hg_status improvements in bash_completion:
authorThomas Arendsen Hein <thomas@intevation.de>
Thu, 26 Jan 2006 15:07:46 +0100
changeset 1639 dbfc04a55607
parent 1638 1c75487badd6
child 1640 9a5b778f7e2d
_hg_status improvements in bash_completion: - Use "hg status -n" option instead of cut command. - Sort status flags accoring to "hg status --help" - Show deleted files instead of "hg remove"d for "hg remove"
contrib/bash_completion
--- a/contrib/bash_completion	Thu Jan 26 14:52:26 2006 +0100
+++ b/contrib/bash_completion	Thu Jan 26 15:07:46 2006 +0100
@@ -39,7 +39,7 @@
 
 _hg_status()
 {
-    local files="$( hg status -$1 . | cut -b 3- )"
+    local files="$( hg status -n$1 . )"
     COMPREPLY=(${COMPREPLY[@]:-} $( compgen -W "$files" -- "$cur" ))
 }
 
@@ -140,19 +140,19 @@
 	    _hg_status "u"
 	;;
 	commit)
-	    _hg_status "mra"
+	    _hg_status "mar"
 	;;
 	remove)
-	    _hg_status "r"
+	    _hg_status "d"
 	;;
 	forget)
 	    _hg_status "a"
 	;;
 	diff)
-	    _hg_status "mra"
+	    _hg_status "mar"
 	;;
 	revert)
-	    _hg_status "mra"
+	    _hg_status "mard"
 	;;
 	clone)
 	    local count=$(_hg_count_non_option)