Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
colons in names to scp
- X-seq: zsh-users 9897
- From: Deliverable Mail <deliverable@xxxxxxxxx>
- To: zsh-users@xxxxxxxxxx
- Subject: colons in names to scp
- Date: Thu, 9 Feb 2006 12:58:46 -0800
- Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:mime-version:content-type; b=ksEprTnxiAyyCUIeEqlJhAumekkL3TTrdT3xdvccWcVOx2XJJnDWd2b+rHzpK9C/5UjY/Yxh9IDZi7mrb/0ZpXKfSf7IJ5pCcJnJjzD4DzG7L0VDQjAhgKlNwVeD5N7QR1YmvHH87q9nNtW6zC7akA8frWtNMH5oa1kNB9sRhmM=
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
I need to copy files via scp from a zsh script. Say, $1 holds a file name containing ':'. When I do
scp $1 $host:$dir
I get an error from scp, treating the prefix of $1 before : as a source host name. What's the right way to quote it -- '$1' would preclude interpolation of $1, which is exactly why $1 is used in the first place..
Cheers,
Alexy.
Messages sorted by:
Reverse Date,
Date,
Thread,
Author