1. build_commandline docs

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

new topic     » topic index » view message » categorize

2. Re: build_commandline docs

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; }'""" } ) 
new topic     » goto parent     » topic index » view message » categorize

Search



Quick Links

User menu

Not signed in.

Misc Menu