Reputation: 5351
I have problems passign windows path to an non-Cygwin application in Cygwin
app 'd:\path\file'
That application gives an error of /d:/path/file does not exist
.
How stop Cygwin with modifying the input argument in this case?
It prepends / to the path.
It does not prepend, it just looks so by the misleading error message.
Upvotes: 0
Views: 337
Reputation: 28752
Which version are you using? I don't see that with my cygwin. You may have better luck with
app "$(cygpath -ma <cygwin-path<)"
My environment:
$ cygcheck -c bash cygwin
Cygwin Package Information
Package Version Status
bash 4.1.10-4 OK
cygwin 1.7.9-1 OK
$ cat check.bat
@echo %1%
$ ./check.bat 'c:\cygwin\tmp\t'
c:\cygwin\tmp\t
Upvotes: 0
Reputation: 28762
You can protect the path by enclosing in quotes e.g. notepad "c:\a.txt"
. You also might need to protect the backslash (\
) characters in the path by doubling them (notepad "c:\\a.txt"
).
Upvotes: 1