Given a command:
ssh user@host command
where command
, when executed on the remote host host
, should be:
somecmd --option1 'option value with spaces' 'arg1 with spaces' 'arg2 with weird chars, like ('
How can I execute this command using the Haskell Shelly or the Haskell Turtle?
Shelly provides a sshPairs
, but it didn't quote command
correctly.
Quoting in a bash script can be fragile, does these two libraries, (or any Haskell libraries, for that matter), tries to improve this?