in reply to Environmental Settings

You could attach all the commands together and send them in one big command, separated by semicolons:
$command = "/PATH/initialize system; /PATH/skew.k blahblah; more comma +nds; exit"; system($command);

Replies are listed 'Best First'.
RE: Re: Environmental Settings
by arcterex (Acolyte) on Apr 28, 2000 at 03:04 UTC
    Probably best to use && instead, as: system("command1 && command2 && command3") so that if command1 fails, command2 and 3 won't excecute. This is useful if further commands depend on previous commands (or could have bad consequences if they aren't executed).

    A better way would be to write a shell script that takes 2 arguments and then call that from perl. Ie:

    script.sh #!/bin/bash /PATH/initialize_system
    /PATH/skew.k $1
    /PATH/savegif.k $2

    And then your perl script just runs:

    system("script.sh $arg_for_frame_number $frame_number");

    I guess the shell script could be perl too, but there is more than one way to do it :)