From: Bart Schaefer <schaefer@brasslantern.com>
To: zsh-users@sunsite.dk
Subject: Re: scp and noglob
Date: Mon, 29 Nov 2004 17:59:47 -0800 (PST) [thread overview]
Message-ID: <Pine.LNX.4.61.0411291728410.25119@toltec.zanshin.com> (raw)
In-Reply-To: <20041129205603.GA5217@kubieziel.de>
On Mon, 29 Nov 2004, Jens Kubieziel wrote:
> scp $SERVER:*.c .
> Zsh tries to expand *.c and I have to insert a 'noglob'. Is there a way
> to tell zsh to don't expand all filenames which are on the serverside?
If you have zsh 4.2.x, try the url-quote-magic widget that's included in
the Functions/Zle directory in the distribution. Load it like this:
autoload -U url-quote-magic
zle -N self-insert url-quote-magic
Then trick it into treating any hostname as a URL scheme when the command
name is "scp", by doing this (note placement of single/double quotes):
zstyle -e :urlglobber url-other-schema \
'[[ $words[1] == scp ]] && reply=("*") || reply=(http https ftp)'
(Read the comments in the function file for an explanation of why the
context is ":urlglobber", if you care.)
Then just type your scp command and watch what happens.
prev parent reply other threads:[~2004-11-30 2:01 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-11-29 20:56 Jens Kubieziel
2004-11-29 22:19 ` Jay Guerette
2004-11-30 0:26 ` Philippe Troin
2004-11-30 9:10 ` David Gómez
2004-11-30 1:59 ` Bart Schaefer [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Pine.LNX.4.61.0411291728410.25119@toltec.zanshin.com \
--to=schaefer@brasslantern.com \
--cc=zsh-users@sunsite.dk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).