Patchwork [2,of,2] bash_completion: allow remove to complete normal files

login
register
mail settings
Submitter Bryan O'Sullivan
Date March 14, 2013, 9:42 p.m.
Message ID <9fac83b980b22c7a296e.1363297326@australite.local>
Download mbox | patch
Permalink /patch/1129/
State Accepted
Commit e3e601969ba1e56defad1c27dbdf9379cf9954c4
Headers show

Comments

Bryan O'Sullivan - March 14, 2013, 9:42 p.m.
# HG changeset patch
# User Bryan O'Sullivan <bryano@fb.com>
# Date 1363297271 25200
# Node ID 9fac83b980b22c7a296e96026d67f32ba88c150b
# Parent  3e6874c851bebe2ca4b3e010a67291f5b654f256
bash_completion: allow remove to complete normal files

Previously, we only completed files that had been manually deleted. That
behaviour made no sense.
Bryan O'Sullivan - March 14, 2013, 11:11 p.m.
On Thu, Mar 14, 2013 at 3:08 PM, Kevin Bullock <
kbullock+mercurial@ringworld.org> wrote:

> What's the 'n' supposed to do? _hg_status() already passes '-n' to 'hg
> status'...
>

That was supposed to be 'c', but I didn't notice until after I sent the
mail :-)

Patch

diff --git a/contrib/bash_completion b/contrib/bash_completion
--- a/contrib/bash_completion
+++ b/contrib/bash_completion
@@ -255,7 +255,7 @@  shopt -s extglob
 	    _hg_status "mar"
 	;;
 	remove)
-	    _hg_status "d"
+	    _hg_status "nmd"
 	;;
 	forget)
 	    _hg_status "a"