This is the mail archive of the cygwin mailing list for the Cygwin project.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
Greetings, All! I think I've finally ironed out most of the issues I had with it. (Infinite number of arguments, quoting, etc.) The only known issues that cause script to break seems to be the same as you would expect with direct script executions - uneven/misplaced quotation marks. How to use: Place the attached script as /bin/cygwrap.cmd (placement is important, as the script working out certain paths relative to its location). Run the script. Short notice should appear, mentioning usage and registration process. Run the script with "--install" option. By default, the script only register the ".sh" extension. You may list additional extensions after "--install", space-separated. F.e. cygwrap.cmd --install .pl .py Then try executing a simple test.sh[1] script with all kind of arguments and see if there's any significant discrepancy in what you pass to the script and what is actually interpreted from your input. Keep in mind, that "="(equality sign) is a parameter separator in CMD, and parameters containing it must be enclosed in double quotes. If you want to execute Cygwin scripts from native CMD scripts through this association, and/or use CMD completion/executable search functions, you will need to adjust your %PATHEXT% variable to include relevant extensions. F.e. PATHEXT=.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC;.BTM;.PHP;.SH If you are not happy with wrapper prepending Cygwin's bin directory to the %PATH%, i.e. if you already have your path set up to include Cygwin/bin, feel free to comment out the relevant line from the script. [1] #!/bin/sh -x echo "$PATH" echo $#: "$@" -- WBR, Andrey Repin Sorry for my terrible english...
Attachment:
cygwrap.txt
Description: Text document
-- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |