I’m trying to run multiple commands in the shell from ruby but I can’t
seem to grasp how I keep the “state” from the previous shell command.
For example, how would I perform the following sequence of commands in
- cd /dir
Not counting “ls /dir” that is
I’ve tried using:
system “cd /dir”
…but it doesn’t work.