On Mon, 04 May 2009 18:45:59 -0500, fpefpe <> wrote:
|the awk cmd is
|
|awk `{ print $1}`
|
|I used the ` char since the jpsoft doc note that the contents are pass
|to the program as-is, but gawk generate an error message that ` is
|invalid -- how is the ` getting into the gawk program
I can't explain it but I doubt they're being passed to awk (unless awk is
somehow special). TCC just doesn't do that. For example:
v:\> u:\EchoArgs.exe `{ print $1 }`
u:\EchoArgs.exe
{
print
$1
}
Have you perhaps used SETDOS to disable the back-quote?
--
- Vince
Greetings --
No, I don't think that I turned of quoting with setdos.
I was trying to run gawk command using the back tick ` prevent the
command line from being process. I kept getting errors, so I wrote a simple C
program to echo the contents of the argv array passed into the program. In
addition, I also called the win/api "GetComamndLine" to get the complete command
line
If I am reading the doc correctly, the ` character when used to start and end an
argument, should be striped way and the text between them passed to the program
in the same way the ' work for unix shell.
From my simple program, that does not seem to be the case -- Did I miss read
the doc?
Thanks
Frank Esposito
Sample program output -->
Cmd line {args this is a `test`}
Args Count: 5
Argument(0) is {args}
Argument(1) is {this}
Argument(2) is {is}
Argument(3) is {a}
Argument(4) is {`test`}