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]

Re: tr command suddenly behaves differently


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

According to Logu on 9/23/2006 4:46 AM:
> After analysing I found that the tr command did not work correctly. So
> the command
> $ /usr/bin/tr [:upper:] [:lower:]

There's your problem.  You didn't quote properly.  Try:
$ echo [:upper:] [:lower:]
to see what you were really invoking, then try:
$ tr '[:upper:]' '[:lower:]'
to do what you meant.

My guess is that you have a file in your home directory that uses a single
letter, so the bracket expansion of bash took effect and expanded to that
filename rather than passing through the regex that you thought you typed.

By the way, none of this is cygwin specific.

- --
Life is short - so eat dessert first!

Eric Blake             ebb9@byu.net
volunteer cygwin bash maintainer
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2.1 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFFFdkB84KuGfSFAYARAiMQAJ44gGiyngMpZ5qIn8hE/3gAsmD4VQCfbMHd
U6W30ICqcIH9boe7zPWgi4M=
=yDM0
-----END PGP SIGNATURE-----

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