13 Jun 15 12:00, you wrote to Khelair:
WV> What shell is /bin/sh on your system? Have you tried explicitly
WV> setting #!/bin/bash for instance?
I don't think that would've helped the OP. It's better to avoid BASH-specific
stuff in shell scripts anyway.
On a lot of systems these days /bin/sh is DASH, which is closer in syntax to
the Bourne shell than BASH. Probably safer to use, too.
I use tcsh on the command-line, but always /bin/sh for scripts. Anything really
complicated and I'll use Python.
WV> As port 22 is the default ssh port, you don't have to specify it. You
WV> can just do -e ssh without the hassel of the quotes, for testing.
WV> I do however always use -e 'ssh -o BatchMode=yes' ... YMMV ...
rsync already uses ssh by default, so that's superfluous.
And BatchMode is unnecessary if you're using ssh keys...
--- GoldED+/BSD 1.1.5-b20130910
* Origin: Blizzard of Ozz, Melbourne, Victoria, Australia (3:633/267)
|