cygwin simple tar command fails when issues on command line
Hi,
I can run tar commands just fine inside a cygwin terminal window, but my app needs to issue a cygwin command line tar and I can NOT make it work. I've tried all kinds of quoting and escaping, but I can't figure it out!
Even this one (works great in cygwin window):
tar -tvf dld.gz
...but fails when issued like this:
c:\cygwin\bin\bash.exe -c /usr/bin/tar -tvf dld.gz
/usr/bin/tar: You must specify one of the `-Acdtrux' or `--test-label' options
Try `/usr/bin/tar --help' or `/usr/bin/tar --usage' for more information.
If I add quotes the error becomes:
c:\cygwin\bin\bash.exe -c '/usr/bin/tar tvf dld.gz'
tar (child): gzip: Cannot exec: No such file or directory
tar (child): Error is not recoverable: exiting now
/usr/bin/tar: Child returned status 2
/usr/bin/tar: Error is not recoverable: exiting now
ANY help would be VERY appreciated!!!
|