From 8b5cb53f51c77f5844c49ab89b90b00c93fa9c01 Mon Sep 17 00:00:00 2001 From: Tobias Ulmer Date: Wed, 30 Oct 2013 20:06:30 +0100 Subject: [PATCH] Use ssh_remote_cmd() to create directory Signed-off-by: Tobias Ulmer --- generic/transport.lua | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/generic/transport.lua b/generic/transport.lua index 7fd5a07..969db7a 100644 --- a/generic/transport.lua +++ b/generic/transport.lua @@ -361,12 +361,11 @@ function transport.push_file(sourcefile, durl, location, push_permissions, try_h user = string.format("%s@", u.user) end - local argv = { user..u.servername, "mkdir", "-p", - e2lib.shquote(destdir) } - rc, re = e2lib.ssh(argv) + rc, re = e2lib.ssh_remote_cmd(u, { "mkdir", "-p", destdir }) if not rc then return false, re end + local destserv = string.format("%s%s:", user, u.servername) local destfile = string.format("%s/%s", destdir, destname) destfile = e2lib.shquote(destfile) -- 2.39.5