Making Unix like paths work when using java program from Cygwin
Fri May 18 17:46:00 GMT 2012
On 5/18/2012 8:11 AM, Marilo wrote:
> The java aspect looks like a red herring as not relevant to the problem.
> You want to run a *nix shell script and presumably don't want to write your own bat file doing the same job.
> I'm probably missing something but given that there's cygwin, and it's a *nux script, what about just editing the script for your computer, amending the paths in the script, with a find and replace, so /ABC/XYZ is replaced with /cygdrive/c/ABC/XYZ and running the script in cygwin.
That's a bad thing to do! Now you have deviated and have a unique
version of this script. It will not work 6 months down the road when the
script is updated on the Unix/Linux side and you have to again port it.
Instead carefully test to make sure you're in Cygwin and when in Cygwin
use cygpath appropriately. Then "contribute" the code back from whence
it came so you have a hope that the next version will at least have your
portability changes if not the modifier will simply follow suit and take
into account Cygwin users as you've shown can be done.
Andrew DeFaria <http://defaria.com>
As the shopper placed her groceries on the checkout stand, the bagger
asked her paper or plastic? Doesn't matter, she replied, I'm bisackual.
Problem reports: http://cygwin.com/problems.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
More information about the Cygwin