[PATCH] zsh: fix completions with relative paths

steve at borho.org steve at borho.org
Wed Dec 6 02:37:20 UTC 2006


# HG changeset patch
# User Steve Borho <steve at borho.org>
# Date 1165376144 21600
# Node ID 644f6ad2c0a4bd20ad2a8dd14e3f290944015908
# Parent  9c2c2837e73b405d7cc3685d732db528d47a05e2
zsh: fix completions with relative paths

hg add ../foo/bar[TAB] now does what you expect

diff -r 9c2c2837e73b -r 644f6ad2c0a4 contrib/zsh_completion
--- a/contrib/zsh_completion	Tue Dec 05 21:30:04 2006 -0600
+++ b/contrib/zsh_completion	Tue Dec 05 21:35:44 2006 -0600
@@ -178,7 +178,7 @@ _hg_files() {
 }
 
 _hg_status() {
-  status_files=(${(ps:\0:)"$(_hg_cmd status -0n$1 . 2>/dev/null)"})
+  status_files=(${(ps:\0:)"$(_hg_cmd status -0n$1 ./$PREFIX 2>/dev/null)"})
 }
 
 _hg_unknown() {



More information about the Mercurial-devel mailing list