"daniel" <offstuff / aon.at> schrieb im Newsbeitrag news:3e9527ac$0$16258$91cee783 / newsreader01.highway.telekom.at... > I want to run a script within a script. > Therefor I use the ``system´´ command. I'd prefer to use Kernel.load() if possible. Try this: def Kernel.chdirAndLoad( dir, file, wrap=false ) oldPwd = Dir.pwd begin Dir.chdir( dir ) Kernel.load( file, safe ) ensure Dir.chdir( oldPwd ) end end puts "PWD = #{Dir.pwd}" Kernel.chdirAndLoad( "C:\\Programme\\GNU\\CygWin\\home\\Administrator\\bin\\test", "load-test-loaded.rb" ) puts "PWD = #{Dir.pwd}" Cheers robert