Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

Hi Mongk,

COuld you anyone guide me how to run a shell script from perl program in the same UNIX session in which perl runs?

Thanks for your help.

Regards,
Raja

20050609 Janitored by Corion: Fixed formatting, eliminated PRE tags

  • Comment on running shell script from perl in the same UNIX session

Replies are listed 'Best First'.
Re: running shell script from perl in the same UNIX session
by xorl (Deacon) on Jun 09, 2005 at 13:03 UTC
Re: From perl, run shell script in the same UNIX session
by tlm (Prior) on Jun 09, 2005 at 12:58 UTC

    How about

    system( "my_shell_script.sh" ) == 0 or die "my_shell_script.sh failed: $?";
    See system.

    the lowliest monk

    A reply falls below the community's threshold of quality. You may see it by logging in.
Re: running shell script from perl in the same UNIX session
by kprasanna_79 (Hermit) on Jun 09, 2005 at 13:37 UTC
    Hai Raja,
    Please visit this link for elabrate idea
    --Prasanna.K