sam-fans - fans of the sam editor
 help / color / mirror / Atom feed
From: David Hogan <dhog@cs.su.oz.au>
To: sam-fans@hawkwind.utcs.toronto.edu
Date: Mon, 22 Feb 1993 22:26:28 -0500	[thread overview]
Message-ID: <199302231426.26622.out.babus@cs.su.oz.au> (raw)
In-Reply-To: <93Feb21.235516est.2758@hawkwind.utcs.toronto.edu>

> From:	rob@research.att.com

> 	y/^ +/ x/ +/ c/ /

> that's using ^ again; i thought the exercise was to avoid it.
> at least, that is the exercise i've been working on.

I thought the point was to avoid using it in sub-commands.  Although
the command we are trying to find might have to be the sub-command of
another x command, I suppose.

> when i made my suggestion
> 	x s2/ +/ /g
> i implicitly assumed, as i think did the original poster, that
> each line began with white space.
>[...]

Hmmm, I missed that when I first read the post.
Anyway, here's another way to do it:

	x/[^ ].*/ s/ +/ /g

(Dang! That ^ is unavoidable :-)



      reply	other threads:[~1993-02-23  3:37 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1993-02-22  4:48 rob
1993-02-23  3:26 ` David Hogan [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=199302231426.26622.out.babus@cs.su.oz.au \
    --to=dhog@cs.su.oz.au \
    --cc=sam-fans@hawkwind.utcs.toronto.edu \
    /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).