From: "Peña, Botp" Date: 2006-07-11T20:00:06+09:00 Subject: Re: Is possible to return after exec cmd? # since that is exec's feature. exec replaces current process. # # maybe you want system or ` # # irb(main):004:0> `echo am still here ` # => "am still here\n" # irb(main):005:0> system "echo am still here" # am still here # => true ok, ok, if you really want to run exec, you can do something this stupid, irb(main):012:0> `ruby -e "exec 'pwd'"` => "/root\n" irb(main):014:0> system %q[ruby -e "exec 'pwd'"] /root => true