Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: PATCH: _ssh (scp)
- X-seq: zsh-workers 16568
- From: Clint Adams <clint@xxxxxxx>
- To: Oliver Kiddle <okiddle@xxxxxxxxxxx>
- Subject: Re: PATCH: _ssh (scp)
- Date: Tue, 5 Feb 2002 13:08:50 -0500
- Cc: zsh-workers@xxxxxxxxxx, david@xxxxxxxxxx
- In-reply-to: <20020205174702.GA2325@xxxxxxxx>
- Mailing-list: contact zsh-workers-help@xxxxxxxxxx; run by ezmlm
- References: <20020204175927.GA12977@xxxxxxxx> <20020205102420.39912.qmail@xxxxxxxxxxxxxxxxxxxxxx> <20020205174702.GA2325@xxxxxxxx>
> ls -a1F /dir (thereby getting all the dotfiles and potentially
> respecting the local setting of GLOB_DOTS)
> or
> ls -d1F /dir/* (thereby respecting the remote setting of GLOB_DOTS or
> equivalent)
I opted for the latter, but it doesn't quite work.
3.0.8% SLASH=/
3.0.8% print $SLASH
/
3.0.8% print $SLASH:h
/
4.0.4% SLASH=/
4.0.4% print $SLASH
/
4.0.4% print $SLASH:h
.
Was this change intentional?
Index: Completion/Unix/Command/_ssh
===================================================================
RCS file: /cvsroot/zsh/zsh/Completion/Unix/Command/_ssh,v
retrieving revision 1.8
diff -u -r1.8 _ssh
--- Completion/Unix/Command/_ssh 2002/02/05 18:03:26 1.8
+++ Completion/Unix/Command/_ssh 2002/02/05 18:05:04
@@ -5,13 +5,7 @@
local expl remfiles remdispf remdispd
if zstyle -T ":completion:${curcontext}:" remote-access; then
- if [[ $options[globdots] == "on" ]] && [[ "$PREFIX" == */ || -z "$PREFIX" ]];
- then
- print ssh -a -x ${words[CURRENT]%:*} ls -a1F ${words[CURRENT]#*:}
- remfiles=(${(f)"$(ssh -a -x ${words[CURRENT]%:*} ls -a1F ${words[CURRENT]#*:} 2>/dev/null)"})
- else
- remfiles=(${(f)"$(ssh -a -x ${words[CURRENT]%:*} ls -d1F ${words[CURRENT]#*:}\* 2>/dev/null)"})
- fi
+ remfiles=(${(f)"$(ssh -a -x ${words[CURRENT]%:*} ls -d1F ${${${words[CURRENT]#*:}:h}/\\/(#e)/}/\* 2>/dev/null)"})
remdispf=(${remfiles:#*/})
remdispd=(${(M)remfiles:#*/})
Messages sorted by:
Reverse Date,
Date,
Thread,
Author