zsh-workers
 help / color / mirror / code / Atom feed
* [ejb@ql.org: Bug#243385: zsh: rsync completion expands * too soon]
@ 2004-04-13  1:21 Clint Adams
  2004-04-13  1:37 ` Jay Berkenbilt
  0 siblings, 1 reply; 8+ messages in thread
From: Clint Adams @ 2004-04-13  1:21 UTC (permalink / raw)
  To: zsh-workers; +Cc: 243385-forwarded, ejb

I assume that this is a quoting issue again.

----- Forwarded message from Jay Berkenbilt <ejb@ql.org> -----

Date: Mon, 12 Apr 2004 15:59:30 -0400
From: Jay Berkenbilt <ejb@ql.org>
To: Debian Bug Tracking System <submit@bugs.debian.org>
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 -----


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2004-04-25  2:07 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-04-13  1:21 [ejb@ql.org: Bug#243385: zsh: rsync completion expands * too soon] Clint Adams
2004-04-13  1:37 ` Jay Berkenbilt
2004-04-13  2:19   ` Clint Adams
2004-04-13 16:17     ` Jay Berkenbilt
2004-04-13 17:44       ` Bart Schaefer
2004-04-13 22:55         ` Clint Adams
2004-04-14 16:37           ` more boring zsh-in-Arch chatter [was Re: [ejb@ql.org: Bug#243385: zsh: rsync completion expands * too soon]] Clint Adams
2004-04-25  2:07             ` more boring zsh-in-Arch chatter Clint Adams

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).