From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 7247 invoked from network); 13 Apr 2004 01:21:56 -0000 Received: from sunsite.dk (130.225.247.90) by ns1.primenet.com.au with SMTP; 13 Apr 2004 01:21:56 -0000 Received: (qmail 5061 invoked by alias); 13 Apr 2004 01:21:48 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 19761 Received: (qmail 4976 invoked from network); 13 Apr 2004 01:21:47 -0000 Received: from localhost (HELO sunsite.dk) (127.0.0.1) by localhost with SMTP; 13 Apr 2004 01:21:47 -0000 X-MessageWall-Score: 0 (sunsite.dk) Received: from [130.225.247.86] by sunsite.dk (MessageWall 1.0.8) with SMTP; 13 Apr 2004 1:21:47 -0000 Received: (qmail 12573 invoked from network); 13 Apr 2004 01:21:47 -0000 Received: from acolyte.scowler.net (216.254.112.45) by a.mx.sunsite.dk with SMTP; 13 Apr 2004 01:21:45 -0000 Received: by acolyte.scowler.net (Postfix, from userid 1000) id 64C4270047; Mon, 12 Apr 2004 21:21:17 -0400 (EDT) Date: Mon, 12 Apr 2004 21:21:17 -0400 From: Clint Adams To: zsh-workers@sunsite.dk Cc: 243385-forwarded@bugs.debian.org, ejb@ql.org Subject: [ejb@ql.org: Bug#243385: zsh: rsync completion expands * too soon] Message-ID: <20040413012117.GA9729@scowler.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.5.1+cvs20040105i X-Spam-Checker-Version: SpamAssassin 2.63 on a.mx.sunsite.dk X-Spam-Level: X-Spam-Status: No, hits=0.0 required=6.0 tests=none autolearn=no version=2.63 X-Spam-Hits: 0.0 I assume that this is a quoting issue again. ----- Forwarded message from Jay Berkenbilt ----- Date: Mon, 12 Apr 2004 15:59:30 -0400 From: Jay Berkenbilt To: Debian Bug Tracking System Subject: Bug#243385: zsh: rsync completion expands * too soon Package: zsh Version: 4.1.1-14 Severity: normal Tags: patch (Unless zsh-workers has been reconfigured since my last bug report, the X-Debbugs-CC to zsh-workers will fail and this bug will not have been reported upstream.) This is essentially identical to what I reported in Debian bug 239070 for scp: the same bug existed with rsync's completion function. The attached patch removes "_call_program files" from the ssh line used to generate remote files and also adds the -L flag to ls, just like my earlier patch to _ssh. I have dispensed with a lengthy explanation because it is essentially identical to the one I included in bug 239070, the fix to which appears to have been accepted upstream. This patch is to /usr/share/zsh/4.1.1/functions/Completion/Unix/_rsync. -------8<-------- --- _rsync~ 2004-03-25 13:29:33.000000000 -0500 +++ _rsync 2004-04-09 18:14:08.000000000 -0400 @@ -37,7 +37,7 @@ if zstyle -T ":completion:${curcontext}:" remote-access; then slash=/ - remfiles=(${(f)"$(_call_program files ssh -a -x ${words[CURRENT]%:*} ls -d1F ${${${words[CURRENT + remfiles=(${(f)"$(ssh -a -x ${words[CURRENT]%:*} ls -d1FL ${${${words[CURRENT ]#*:}:h}/${slash}(#e)/}/\* 2>/dev/null)"}) remdispf=(${remfiles:#*/}) -------8<-------- This patch causes rsync completion to work properly for remote files when you have ssh access to the remote system. It still doesn't behave quite as well as scp completion (rsync host:/path/ TAB doesn't show alternatives unless you type at least one character after the /), but at least it behaves as well as it did before the _call_program function call was added. A grep for '_call_program files ssh' suggests that this may be the only place left that has this particular bug. Too bad I didn't think to do that last time. :-) Please let me know if additional information is required or if I should have repeated the information to substantiate this patch. -- System Information: Debian Release: testing/unstable APT prefers unstable APT policy: (500, 'unstable') Architecture: i386 (i686) Kernel: Linux 2.4.25-1-686-smp Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 Versions of packages zsh depends on: ii debconf 1.4.16 Debian configuration management sy ii libc6 2.3.2.ds1-11 GNU C Library: Shared libraries an ii libcap1 1:1.10-13 support for getting/setting POSIX. ii libncurses5 5.4-2 Shared libraries for terminal hand ii passwd 1:4.0.3-21 Change and administer password and -- debconf information: zsh/rcmove: --- _rsync~ 2004-03-25 13:29:33.000000000 -0500 +++ _rsync 2004-04-09 18:14:08.000000000 -0400 @@ -37,7 +37,7 @@ if zstyle -T ":completion:${curcontext}:" remote-access; then slash=/ - remfiles=(${(f)"$(_call_program files ssh -a -x ${words[CURRENT]%:*} ls -d1F ${${${words[CURRENT + remfiles=(${(f)"$(ssh -a -x ${words[CURRENT]%:*} ls -d1FL ${${${words[CURRENT ]#*:}:h}/${slash}(#e)/}/\* 2>/dev/null)"}) remdispf=(${remfiles:#*/}) ----- End forwarded message -----