[lug] grep question

Hugh Brown hugh at math.byu.edu
Tue Jun 12 09:00:52 MDT 2007



On Tue, 12 Jun 2007, Chip Atkinson wrote:

> Ok, here's something to chew on:
>
> chip at chip1:~> echo $LANG
> en_US.UTF-8
> chip at chip1:~> echo abc | grep A
> chip at chip1:~> echo abc | grep a
> abc
> chip at chip1:~> echo abc | grep "[A-Z]"
> abc
> chip at chip1:~> export LANG=C
> chip at chip1:~> echo abc | grep "[A-Z]"
> chip at chip1:~>
>
> The distribution is SuSE enterprise linux.  It seems that the LANG stuff
> only affects an expression in set of mini-experiments.
>
> Another thing that is odd is that there are many programs in /usr/bin with
> symlinks to their counterpart in /bin.  However, /usr/bin isn't a symlink
> to /bin.  I guess SuSE is "non-standard", but I thought it was a Red Hat
> derivative.
>
> Chip


On a RH5 box, I don't get anything returned from  echo abc | grep "[A-Z]"
and LANG is en_US.UTF-8.  I'd check to see if it is always reproducible on
SuSE.  If it is, I'd file a bug report.

According to wikipedia, SuSE was a slackware translation.  They did adopt
rpm as a package format, but that's about it.

I think the only distro with widespread use that is still like Redhat is
CentOS.  Otherwise, the distro just seems to share rpm as a package format
(e.g. Mandriva) and doesn't have much else in common.

Hugh



More information about the LUG mailing list