in reply to system & exec

source is not an executable file, but a builtin command of the shell. Therefore you need to invoke it through the shell:

system 'bash -c "source yourscript.sh"'

Anyway, using source doesn't make sense in that context. You probably should just invoke your shell script directly.

Replies are listed 'Best First'.
Re^2: system & exec
by ikegami (Patriarch) on Jul 28, 2018 at 19:15 UTC

    No reason to invoke two shells. Fixed:

    system 'bash', '-c', 'source yourscript.sh'