On Thu, Jan 04, 2001 at 03:17:14PM +1100, raf <[EMAIL PROTECTED]> wrote:
| i often need to use different rsh-like commands depending on the host
| i'm rsyncing with (for any given host). e.g.
|
| from A to B, "rsh" is ok
| from A to Q, "ssh" is needed
| from A to Z, "runsocks ssh -x -l other-username" is needed
|
| the RSYNC_RSH environment variable can't cope with this and
| having to use the -e option all the time gets very boring,
| so here's a patch (against rsync-2.4.6) that implements a
| $HOME/.rsyncrc file with the following format:
| "host" <hostname> ["user" <username>] "rsh" <rsh-like command>
And supposing I want different commands per invoking user or something else?
This seems like flexibility you don't need (or want) to put into rsync.
Just set RSYNC_RSH to the path of a shell script with this intelligence.
Works for me, and is arbitrarily flexible. Keeps rsync itself simple.
--
Cameron Simpson, DoD#743 [EMAIL PROTECTED] http://www.zip.com.au/~cs/
Kryten: It seems, after all this time, that Mr Lister is a robot.
Rimmer: I'll write you into my will if you let me tell him.