zsh-workers
 help / color / mirror / code / Atom feed
From: Roman Neuhauser <dev-null@bellavista.cz>
To: Julian Foad <julianfoad@btopenworld.com>
Cc: Philip Martin <philip@codematters.co.uk>,
	dev@subversion.tigris.org, Sebastien Cevey <seb@cine7.net>,
	Clint Adams <clint@zsh.org>,
	zsh-workers@sunsite.dk
Subject: Re: [PATCH] bash_completion: improvement, fixes and tests [was: Re: subversion and programmable completion]
Date: Mon, 18 Aug 2003 11:24:35 +0200	[thread overview]
Message-ID: <20030818092435.GD94462@freepuppy.bellavista.cz> (raw)
In-Reply-To: <3F1F3685.5040005@btopenworld.com>

# julianfoad@btopenworld.com / 2003-07-24 02:29:41 +0100:
> Philip Martin wrote:
> >Julian Foad <julianfoad@btopenworld.com> writes:
> >
> >>   # Find the relevant lines;
> >>   # remove brackets and commas; put each word on its own line.
> >>   sed -n -e '1,/^Available subcommands:$/d;/^$/q' \
> >>          -e 's/[ )]//g;s/[(,]/\n/g;p' |
> >
> >$ sed -V | head -1
> >GNU sed version 3.02
> >$ echo 'x(y' | sed 's/[(,]/\n/g'
> >xny
> 
> Oh dear.  I don't know why you get that.

    because that's what it's supposed to do. read the sed description in
    SUSv3. (I'd quote the two paragraphs here but I fear breaking the
    ToS...) basically:

    * \n is not a valid replacement metacharacter
    * behavior of \X where X is not one of &, <digit>, <delimiter> or
      <newline> is undefined
    * if you want to embed a newline in the replacement, do it this way:

    sed 's/BRE/first part\
    second part/'

    Julian, looks like your sed is broken.
    I know I'm coming awfully late, but wanted to make this clear.

-- 
The From: header's been munged to get rid of unwanted cc's.
My real address: neuhauser@bellavista.cz.


      parent reply	other threads:[~2003-08-18  9:31 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-07-20 16:27 subversion and programmable completion Clint Adams
2003-07-21 15:15 ` kfogel
2003-07-21 22:48   ` Clint Adams
2003-07-21 18:33 ` Sebastien Cevey
2003-07-21 22:52   ` Clint Adams
2003-07-23 19:31   ` [PATCH] bash_completion: improvement, fixes and tests [was: Re: subversion and programmable completion] Julian Foad
2003-07-23 21:27     ` Philip Martin
2003-07-24  1:29       ` Julian Foad
2003-07-24  5:46         ` Philip Martin
2003-08-18  9:24         ` Roman Neuhauser [this message]

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=20030818092435.GD94462@freepuppy.bellavista.cz \
    --to=dev-null@bellavista.cz \
    --cc=clint@zsh.org \
    --cc=dev@subversion.tigris.org \
    --cc=julianfoad@btopenworld.com \
    --cc=philip@codematters.co.uk \
    --cc=seb@cine7.net \
    --cc=zsh-workers@sunsite.dk \
    /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.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

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).