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]

Why bash failed to match this pattern?


Hi All,

My current version of bash on cygwin failed to match this pattern:
*******************************
target=ar
if [[ "$target" =~ '^a' ]]; then
    echo Matched
else
    echo Unmatched
fi
*******************************

$bash --version
GNU bash, version 3.2.48(21)-release (i686-pc-cygwin)
Copyright (C) 2007 Free Software Foundation, Inc.

The older version of bash can match the same pattern before I upgrade cygwin.
What is the possible reason?

PRC
Jun 5, 2009

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