I was just trying to get some Python to work and decided to wrap it in a shell script in Cygwin on Windows XP so that I wouldn't have to convert a batch file to a shell script later on when I copied it to a Unix server.
Of course, when I ran the script, Bash complained that the interprerter mentioned in the #! line wasn't there. In a fit of non Unix compatibility I just replaced /usr/bin with the correct path of my Python exe on Windows.
I should have tested this before updating all my files as Bash choked on the spaces in the path to my Python exe. After some mad Googling to find out how to escape this properly I gave up and did what I should have done in the first place.
I went over to my Cygwin's /usr/bin and made in a symbolic link to the Python exe in my Windows installation of Python. For some reason, I didn't expect symbolic links made in Cygwin on Windows to work but it worked perfectly.
Also, as usual, I reversed the arguments for "ln" the first time I tried to make the link. It always seems backwards to me and the help text doesn't make it obvious which is the source and which the destination.
What I found interesting was that I assumed that putting in the windows path would work the most quickly and it would be less effort to do a temporary fix which I would have to fix later than to try and use "ln".
Posted by stuartcw at January 17, 2004 03:00 PMCygwin is so neat, I'm considering NOT installing Linux on my next laptop(!)
I too used to get the arguments to ln mixed up. I now remember that 'ln' is like 'cp' or 'mv', in that the new thing is the last argument. This even made a certain amount of sense when I learnt that, in the bad old days of Unix, ln, cp and mv were just three symbolic links to the one executable.
Posted by: Alan Green at January 18, 2004 12:48 PMThe mental trick I used to get used to the ln param order (I had the same instinctive ordering as you) was to 'pretend' the -s stood for 'source' rather than 'symbolic' (this works because I almost always make symbolic links instead of hard links).
Posted by: Dav at January 23, 2004 07:54 AM