I have the following scenario.
I have a Perl script that takes an ID and looks up some arguments from a DB.
look_up_args.pl 234 prints the following
abc 123 "something with spaces"
I have another shell script
script.sh that does the following
some_command --param1 $1 --param2 $2 --par3 "$3" ...
what I am trying to do is to call the script with the arguments
I have tried the following 2 methods
./script.sh `./look_up_args.pl 234` ./script.sh $(./look_up_args.pl 234)
still whenever I run the
$3 seems to contain only
"something" causing my script to fail. I am looking for away to pass the quoted string with out any form of shell expansion/etc... The third parameter may contain other special bash characters, but will always be quoted.