Fixed bug #36660: --workdir mkdir does not use --sshlogin custom ssh.

This commit is contained in:
Ole Tange 2012-06-14 22:19:49 +02:00
parent 72402ef16e
commit 67d4db2279
3 changed files with 10 additions and 1 deletions

View file

@ -3405,7 +3405,7 @@ sub sshtransfer {
if(-r $file) {
my $mkremote_workdir =
$remote_workdir eq "." ? "true" :
"ssh $serverlogin mkdir -p $rsync_destdir";
"$sshcmd $serverlogin mkdir -p $rsync_destdir";
$pre .= "$mkremote_workdir; rsync $rsync_opt "
. ::shell_quote_scalar($file)." $serverlogin:$rsync_destdir;";
} else {

View file

@ -28,4 +28,11 @@ seq 1 60000 | parallel -I :: -X -j1 echo a::b::c |
echo "### bug #36659: --sshlogin strips leading slash from ssh command"
parallel --sshlogin '/usr/bin/ssh localhost' echo ::: OK
echo "### bug #36660: --workdir mkdir does not use --sshlogin custom ssh"
cd /tmp; echo OK > parallel_test.txt;
ssh () { echo Failed; };
export -f ssh;
parallel --workdir /tmp/foo/bar --transfer --sshlogin '/usr/bin/ssh localhost' cat ::: parallel_test.txt;
EOF

View file

@ -84,3 +84,5 @@ Chars per line (697800/6): 116300
Chars per line (817788/7): 116826
### bug #36659: --sshlogin strips leading slash from ssh command
OK
### bug #36660: --workdir mkdir does not use --sshlogin custom ssh
OK