Want to let variable pass to cygstart.

Phil Betts Phil.Betts@ascribe.com
Wed Mar 11 09:05:00 GMT 2009


Hongyi Zhao wrote:
> On Wed, 11 Mar 2009 04:37:46 +0000, Dave Korn
> <dave.korn.cygwin@xxxxxxxxxx.xxx> wrote:

Please don't quote raw email addresses.  It only feeds the spammers.

> >  It's bash shell metacharacters.  The '&' character terminates a
> command and
> >puts it into the background.  The simplest way is to use single
quotes
> ' '
> >around the URL you want to cygstart.
> 
> Thanks a lot.

Except that single quotes will also prevent variable substitution.  If 
you want to use metacharacters AND variables, you have to use the 
backslash to escape the metacharacters.

Alternatively, you could concatenate strings like this:
  'stringA&stringB'$variable'stringC&stringD'


Phil
-- 


This email has been scanned by Ascribe PLC using Microsoft Antigen for Exchange.

--
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/



More information about the Cygwin mailing list