[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Unifying BSD sed -E and GNU sed -r options?

From: Dan Kegel
Subject: Re: Unifying BSD sed -E and GNU sed -r options?
Date: Tue, 21 Jan 2014 11:25:14 -0800

Right, but for now, I have to check platform before using it, e.g.

    case $_os in
    osx*) xregx=-E;;
    *) xregx=-r;;
    ... sed $xregx ...

I'd like it if either -r or -E worked on both gnu and bsd sed.
So this is a standardization enhancement request,
and it's possible bsd is the one that should change.
I have not yet done a search to see which of the two options
is used more in practice.

On Tue, Jan 21, 2014 at 11:08 AM, Davide Brini <address@hidden> wrote:
>> Dan Kegel wrote:
>> It'd be nice to be able to use extended regexps in script
>> run on both bsd and gnu.
>> Has this issue been raised before? I couldn't find a bug tracker;
>> http://savannah.gnu.org/projects/sed doesn't list one.
> AFAIK, GNU sed has supported -E for quite some time (though it was, or 
> perhaps it's still, undocumented).

reply via email to

[Prev in Thread] Current Thread [Next in Thread]