Skip site navigation (1)Skip section navigation (2)
Date:      20 Feb 2005 20:32:22 +0100
From:      Rasmus Kaj <kaj@kth.se>
To:        Jeremie Le Hen <jeremie@le-hen.org>
Cc:        freebsd-current@freebsd.org
Subject:   Re: pcre in base system
Message-ID:  <rqczmxzt4c9.fsf@kashyyyk.admin.kth.se>
In-Reply-To: <20050218080214.GQ82324@obiwan.tataz.chchile.org>
References:  <72c3a957050217031230598f63@mail.gmail.com> <86zmy3qmm2.wl%sf@FreeBSD.org> <72c3a957050217065223729f83@mail.gmail.com> <20050217185422.GJ57256@cirb503493.alcatel.com.au> <20050218003534.GA31807@neveragain.de> <20050218080214.GQ82324@obiwan.tataz.chchile.org>

next in thread | previous in thread | raw e-mail | index | archive | help
>>>>> "JLH" == Jeremie Le Hen <jeremie@le-hen.org> writes:

 >> But, well, it would actually be nice if PCREs would be available as an
 >> *option*. Analogue to grep, grep -E / sed, sed -E, ...

 JLH> Note that the pcre port is shipped with the pcregrep command.
 JLH> There is unfortunately no pcresed or pcreawk command.

If someone wants a *really* perl compatible sed, why not just use
perl?

perl -p -e 's/regex/replacement/'

is the same thing as

sed -e 's/regex/replacement/'

except, of cource, for the differences in regex (and replacement)
syntax.  A similar replacement is easily created for awk (see the
perlrun manpage).


-- 
Rasmus Kaj ----------------------------------------------- rasmus@kaj.se
 \ Send me all ``mail viruses'' you want - I use Unix, secure by default.
  \------------------------------------- http://www.stacken.kth.se/~kaj/



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?rqczmxzt4c9.fsf>