[Tutor] how to control putty window
Alan Gauld
alan.gauld at btinternet.com
Thu Dec 20 18:39:52 CET 2012
On 20/12/12 14:25, Ufuk Eskici wrote:
> Hello,
>
> I run this command and opens putty:
>
> import os
> import subprocess
> command = '"c:\Program Files\Putty\putty.exe" -ssh
> ufukeskici at 10.10.10.10 <mailto:ufukeskici at 10.10.10.10> -pw test
> subprocess.Popen(command)
>
> But then I want to input new commands to this Putty new window. How can
> I do it?
I don't know putty.
But if it reads/writes to stdin/out/error then you can use the options
to Popen as described in the subprocess docs.
If it doesn't use stdin/out etc then its a much bigger problem.
--
Alan G
Author of the Learn to Program web site
http://www.alan-g.me.uk/
More information about the Tutor
mailing list