From: Daniel Pittman Date: 2010-12-20T07:47:01+09:00 Subject: Re: Please help with NET::SSH On Mon, Dec 20, 2010 at 05:47, Jean-eric Godard wrote: > I use the NET::SSH gem, and I have some trouble using it, I can't send > successive command. > Per example when I type the commands : > "ls" followed by "cd desktop" and then "ls" again. > the second time  I send "ls", return me the exact same list as the first > "ls" send the "cd desktop" command is ignored. > net::ssh act like if it open a new terminal for each command send. It is: the 'exec' operation opens a new channel to the server, runs the given command, then closes it. To do what you want there you would need to exec /bin/sh, then drive that with send_input. Regards, Daniel -- ✣ Daniel Pittman            ✉ daniel@rimspace.net            ☎ +61 401 155 707               ♽ made with 100 percent post-consumer electrons