[PATCH 2 of 2] bash_completion: diff: recognize the --output option

Ahmed S. Darwish darwish.07 at gmail.com
Fri Jun 28 16:38:55 CDT 2013


Hi,

[ More accurate commit log ]

On Sat, Jun 29, 2013, Nikolaj Sjujskij wrote:
> Den 2013-06-29 00:13:31 skrev Ahmed S. Darwish <darwish.07 at gmail.com>:
>
> > ...
> ># Parent  3466620d7f96769c469f7e42b08f1ca3d53feb86
> >completion: recognize the --output option
>  It's *bash*_completion.
> 

# HG changeset patch
# User Ahmed S. Darwish <darwish.07 at gmail.com>
# Date 1372455074 -7200
# Node ID af588dca01e19a5ce367bdec663e561ad89080bf
# Parent  af3661f6c703d11dea0b490818f33826403e6d21
bash_completion: diff: recognize the --output option

`diff --output <TAB>' now only lists the repository untracked files.

diff -r af3661f6c703 -r af588dca01e1 contrib/bash_completion
--- a/contrib/bash_completion	Fri Jun 28 22:54:47 2013 +0200
+++ b/contrib/bash_completion	Fri Jun 28 23:31:14 2013 +0200
@@ -255,7 +255,11 @@
 	    _hg_debugpathcomplete -fa
 	;;
 	diff)
-	    _hg_status "mar"
+	    if [[ "$prev" = @(-o|--output) ]]; then
+	     	_hg_status "u"
+	    else
+		_hg_status "mar"
+	    fi
 	;;
 	revert)
 	    _hg_debugpathcomplete
exporting patch:
<fdopen>

--
Darwish
http://darwish.chasingpointers.com


More information about the Mercurial-devel mailing list