[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: escaping, bash



On Tue, Apr 29, 2003 at 08:40:57PM +0100, Hugh Saunders wrote:
> hugh@nomessin:~$ scp hugh@wacka.mjr.org:~/grant\ letter.doc ~/
> hugh@mjr.org's password:
> scp: /home/hugh/grant: No such file or directory
> scp: letter.doc: No such file or directory

You have to double-quote spaces for scp, so:

  scp hugh@wacka.mjr.org:'~/grant\ letter.doc' ~/

It sucks, but unfortunately the protocol comes from rcp, has been
deployed for twenty years or so, and therefore can't be fixed without
breaking compatibility with a lot of systems. You can use sftp or
rsync-over-ssh as an alternative.

Cheers,

-- 
Colin Watson                                  [cjwatson@flatline.org.uk]



Reply to: