1. build_commandline docs
- Posted by petelomax Jul 28, 2015
- 1196 views
example2 contains
You can use this to run things that might be difficult to quote out:
Suppose you want to run a program that requires quotes on its command line? Use this function to pass quotation marks:
s = build_commandline( { "awk", "-e", "'{ print $1"x"" } )
Surely that is not legal syntax, is it?
Pete
2. Re: build_commandline docs
- Posted by jimcbrown (admin) Jul 28, 2015
- 1194 views
petelomax said...
example2 contains
You can use this to run things that might be difficult to quote out:
Suppose you want to run a program that requires quotes on its command line? Use this function to pass quotation marks:
s = build_commandline( { "awk", "-e", "'{ print $1"x"" } )
Surely that is not legal syntax, is it?
Pete
Nope. I think one of the two were intended:
s = build_commandline( { "awk", "-e", `'{ print $1"x"$2; }'` } ) s = build_commandline( { "awk", "-e", """'{ print $1"x"$2; }'""" } )