git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Simon 'corecode' Schubert <corecode@fs.ei.tum.de>
To: Junio C Hamano <gitster@pobox.com>
Cc: David Kastrup <dak@gnu.org>,
	Johannes Sixt <johannes.sixt@telecom.at>,
	git@vger.kernel.org,
	Johannes Schindelin <Johannes.Schindelin@gmx.de>
Subject: Re: [PATCH] rebase--interactive: do not use one-or-more (\+) in sed.
Date: Sun, 02 Sep 2007 15:39:33 +0200	[thread overview]
Message-ID: <46DABD15.4030208@fs.ei.tum.de> (raw)
In-Reply-To: <7vfy1xr1lz.fsf@gitster.siamese.dyndns.org>

Junio C Hamano wrote:
>> Just for the record: I believe that \{1,\} might be portable.
> 
> Yeah, I obviously looked at the page I quoted that describes
> what's in and what's not in BRE definition ;-)
> 
> But in practice, I do not recall ever seeing an older sed that
> did not understand one-or-more \+ *and* understood \{1,\}.  Do
> you?

Yes, BSD sed (at least DragonFly's, so probably as well FreeBSD-4 (dunno 
about later)):

chlamydia % echo 5ab123x | sed -e 's/[a-z]\+/AAA/' 

5ab123x
chlamydia % echo 5ab123x | sed -e 's/[a-z]\{1,\}/AAA/' 

5AAA123x
chlamydia % echo 5ab123x | sed -E -e 's/[a-z]+/AAA/' 

5AAA123x

cheers
   simon

  parent reply	other threads:[~2007-09-02 13:40 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-09-01  7:25 [PATCH] rebase -m: Fix incorrect short-logs of already applied commits Johannes Sixt
2007-09-01  9:01 ` Junio C Hamano
2007-09-01  9:05   ` [PATCH] rebase--interactive: do not use one-or-more (\+) in sed Junio C Hamano
2007-09-01 22:24     ` Johannes Schindelin
2007-09-02  6:53     ` David Kastrup
2007-09-02  7:02       ` Junio C Hamano
2007-09-02  7:20         ` David Kastrup
2007-09-02 13:39         ` Simon 'corecode' Schubert [this message]
2007-09-02 14:20           ` Johannes Schindelin
2007-09-02 17:07       ` Nix
2007-09-05 17:54         ` Benoit SIGOURE
2007-09-05 18:06           ` Nix
2007-09-01  9:20   ` [PATCH] rebase -m: Fix incorrect short-logs of already applied commits David Kastrup
2007-09-01 12:06   ` Johannes Sixt
2007-09-01 12:11 ` Robin Rosenberg

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=46DABD15.4030208@fs.ei.tum.de \
    --to=corecode@fs.ei.tum.de \
    --cc=Johannes.Schindelin@gmx.de \
    --cc=dak@gnu.org \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=johannes.sixt@telecom.at \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).