Closed pandel closed 9 years ago
What code are you actually using to run the command? Commands are run directly, rather than through a shell, so if you want to use pipes, then you'll need to run an appropriate shell command e.g.
shell.run(["sh", "-c", "atq -q D | cut -f1 | xargs at -q D -c | grep user"])
Yes, your example is one of the variations I tried. After a lot more research I found out, that the command itself is transmitted correctly. But many many thanks for your answer. It made clear how to do it correctly.
Glad to hear you got it sorted.
I'm trying to form complexer commands by concatenating them via pipe symbol and execute them through SshShell.
Commands look like this, i.e.:
atq -q D | cut -f1 | xargs at -q D -c | grep user
I tried to construct a command list for SshShell but nothing seems to work. Isn't it possible at the moment to concat commands via piping?