http://www.perlmonks.org?node_id=477802


in reply to process redirection

What happens if you change directories first?



pbeckingham - typist, perishable vertebrate.

Replies are listed 'Best First'.
Re^2: process redirection
by anonymized user 468275 (Curate) on Jul 25, 2005 at 13:28 UTC
    ...putting that into code and showing how to redirect the other output as well:-
    system( "cd $mydir; $command > cmd.log 2>\&1" );

    One world, one people

Re^2: process redirection
by pavan_gpk (Initiate) on Jul 26, 2005 at 05:03 UTC
    Hi if i change my directory first 'system' cant fetch the executable file in that directory and giving error.. let me explain more clearly what exactly i am looking for i need to run 'build.exe' that generates .cab's/.exe's files in current directory not to STDOUT.but i need to generate those files in the specfied path or directory that i specify.. thanks pavan..