This is the mail archive of the cygwin@cygwin.com 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]

Re: cygwin and the rest of the Windows


Hi:
> In your case 1, it looks like you ran that command
> from bash.
No, I ran it from WINXP command prompt

>It's pretty
> obvious why it didn't work - bash needs POSIX paths.
>  You had unquoted
> spaces, which bash interpreted as argument
> separators, and it also
> interpreted backslashes as escapes.  You should have
> run that command from
> a cmd prompt.
> 
> I also warned you that the name of the script will
> be passed in Win32
> form, and you'd need to use cygpath to convert it to
> POSIX.  The file that
> worked for me (I actually created one that works
> this time) was:
> 
> @echo off
> c:\cygwin\bin\bash.exe --login -c "/usr/bin/perl
> `/bin/cygpath -u '%1'`"
what does this ` character do? just curious, maybe I
should read the POSIX manual

> You can add similar conversions for %2..%9, but I
> don't think they're
> necessary in your particular case (i.e., a file
> handler for the .pl
> extension).  You may not need the "--login" - try
> running without it, that
> will keep you in the same directory.  Oh, and the
> '#!' line would be
> ignored in this case, and the dispatch will be done
> by Windows Explorer
> based solely on the .pl extension.
> 
> As for case 2, you might have to play similar games,
> but in the
> association mechanism.  Something like
> 
> c:\cygwin\bin\bash.exe -c "`cygpath -u '%s'`"
> 
> (I don't have the exact incantation, you may need to
> read up on the
> Windows Explorer mechanism for this).
another curious question...what's %s?

__________________________________
Do you Yahoo!?
SBC Yahoo! DSL - Now only $29.95 per month!
http://sbc.yahoo.com

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]