diff options
author | Sean Whitton <spwhitton@spwhitton.name> | 2021-02-19 09:58:33 -0700 |
---|---|---|
committer | Sean Whitton <spwhitton@spwhitton.name> | 2021-02-19 09:58:33 -0700 |
commit | a58fe2bdec1ea2d16aa075081c8963a7d5a9a1dd (patch) | |
tree | 3346238c4b20937c88eac8d274606615f536564b /src/connection/ssh.lisp | |
parent | 9a244da914e7b00c5b5750e4a8576e35debd38c5 (diff) | |
download | consfigurator-a58fe2bdec1ea2d16aa075081c8963a7d5a9a1dd.tar.gz |
update connection-run for :ssh
Signed-off-by: Sean Whitton <spwhitton@spwhitton.name>
Diffstat (limited to 'src/connection/ssh.lisp')
-rw-r--r-- | src/connection/ssh.lisp | 15 |
1 files changed, 2 insertions, 13 deletions
diff --git a/src/connection/ssh.lisp b/src/connection/ssh.lisp index e9b49f3..12faee1 100644 --- a/src/connection/ssh.lisp +++ b/src/connection/ssh.lisp @@ -35,19 +35,8 @@ (slot-value connection :hostname) (escape-sh-command "sh" "-c" ,@args))) -(defmethod connection-run ((connection ssh-connection) - cmd - &optional - input - environment) - (when environment - (loop do (push (escape-sh-token - (strcat - (symbol-name (pop environment)) "=" (pop environment))) - cmd) - while environment - finally (push "env" cmd))) - (run-with-input input nil (sshcmd cmd))) +(defmethod connection-run ((connection ssh-connection) cmd &optional input) + (run :input input (sshcmd cmd))) (defmethod connection-readfile ((connection ssh-connection) path) (multiple-value-bind (output error-code) |