Results 1 to 4 of 4
Hi,
I was hoping to run a perl script I had written from a bash script. Currently I am using command substitution:
$(perl myPerlScript.pl "argument")
The problem is the perl ...
- 09-20-2007 #1Just Joined!
- Join Date
- Sep 2007
- Posts
- 4
Perl script from bash
Hi,
I was hoping to run a perl script I had written from a bash script. Currently I am using command substitution:
$(perl myPerlScript.pl "argument")
The problem is the perl script requires a couple user interactions and when I run the bash script it won't seem to run it properly. Is there any way to do this?
Thanks in advance.
- 09-21-2007 #2
The $() construct is for executing the code inside the parens, and substituting its output. You want to remove the $ and parens.
- 09-21-2007 #3
Well I think technically, $() means execute in a subshell, but most of the time when I use it, it's for getting a program's output into a variable.
- 09-21-2007 #4Just Joined!
- Join Date
- Sep 2007
- Posts
- 4
That was easy. I appreciate the clarification.


Reply With Quote