help-bash
[Top][All Lists]
Advanced

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

Re: [Help-bash] script with ssh and filenames with spaces


From: Greg Wooledge
Subject: Re: [Help-bash] script with ssh and filenames with spaces
Date: Wed, 17 Jul 2013 16:52:11 -0400
User-agent: Mutt/1.4.2.3i

On Wed, Jul 17, 2013 at 08:42:17PM +0000, address@hidden wrote:
> I wish to ssh this command to several hosts: 
> ls -alst "dir_with_spaces" 

for host in "address@hidden"; do
  ssh "$host" bash <<-'EOF'
        ls -alst "your directory"
        EOF
done

The - in front of the here document's delimiter allows indentation with
tabs only (not spaces).

I Cc'ed address@hidden because that's more appropriate for this
question.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]