On Tue, Feb 05, 2002 at 09:38:04PM -0800, Wayne Davison wrote: > On Wed, 6 Feb 2002, Martin Pool wrote: > > OK, I agree --with-rsh should go in, but I think putting magic > > characters into it is needlessly confusing. I would feel much better > > about a separate configure option to set the default O_NONBLOCK mode. > > The complicating factor then becomes: how does the RSYNC_RSH environment > variable interact with this default O_NONBLOCK mode, and how can the > default blocking be changed via the environment? I came up with the > magic character idea in order to try to keep things simple (using only > one environment variable instead of trying to keep two different ones in > sync). I admit that it's quirky, though. > > So the obvious alternative is something like this: > > export RSYNC_RSH=ssh > export RSYNC_BLOCKING_IO=1 > > Perhaps a better idiom might be allow RSYNC_RSH to begin with a > command-line option? If the string begins with "--blocking-io " we > strip it off and twiddle that command-line flag? If we want to make > this orthogonal we could also add support for the --non-blocking-io > command-line option and allow this string to appear at the start of > the RSYNC_RSH value. What do you think of something like this? > > export RSYNC_RSH='--blocking-io /usr/bin/ssh -l username' > export RSYNC_RSH='--non-blocking-io rsh'
Of the proposed alternatives, I like this latter the best, changing --non-blocking-io to --no-blocking-io. I added --no-blocking-io and --no-whole-file command line options yesterday. - Dave Dykstra