9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
* Re: [9fans] Really basic acme Edit question
@ 2006-10-22  5:37 Joel chesky Salomon
  2006-10-22  7:47 ` Skip Tavakkolian
  0 siblings, 1 reply; 8+ messages in thread
From: Joel chesky Salomon @ 2006-10-22  5:37 UTC (permalink / raw)
  To: 9fans

> commands in 'Edit' apply to selected text (dot) just like Look or |

Also, the command I was looking for was
	x/foo/c/bar
— not so obvious to a beginner.  Thanks fo setting me straight.

--Joel



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [9fans] Really basic acme Edit question
  2006-10-22  5:37 [9fans] Really basic acme Edit question Joel chesky Salomon
@ 2006-10-22  7:47 ` Skip Tavakkolian
  2006-10-22 13:44   ` Joel Salomon
  0 siblings, 1 reply; 8+ messages in thread
From: Skip Tavakkolian @ 2006-10-22  7:47 UTC (permalink / raw)
  To: 9fans

> Also, the command I was looking for was
> 	x/foo/c/bar
> — not so obvious to a beginner.  Thanks fo setting me straight.

it should be noted somewhere that sam structured regexp applies
to Edit.



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [9fans] Really basic acme Edit question
  2006-10-22  7:47 ` Skip Tavakkolian
@ 2006-10-22 13:44   ` Joel Salomon
  0 siblings, 0 replies; 8+ messages in thread
From: Joel Salomon @ 2006-10-22 13:44 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

> it should be noted somewhere that sam structured regexp applies
> to Edit.

It is so noted in acme(1); it just took me a while reading sam(1) to
figure out the proper command syntax.

--Joel


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [9fans] Really basic acme Edit question
  2006-10-22 19:00   ` Joel Salomon
@ 2006-10-22 19:29     ` Russ Cox
  0 siblings, 0 replies; 8+ messages in thread
From: Russ Cox @ 2006-10-22 19:29 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

Commands apply to the current selection in both sam and acme.
The use of , as an address meaning "the entire file" is also common
to both sam and acme.  See the sections starting with "Addresses"
in sam(1).

Russ


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [9fans] Really basic acme Edit question
  2006-10-22 14:38 ` erik quanstrom
@ 2006-10-22 19:00   ` Joel Salomon
  2006-10-22 19:29     ` Russ Cox
  0 siblings, 1 reply; 8+ messages in thread
From: Joel Salomon @ 2006-10-22 19:00 UTC (permalink / raw)
  To: 9fans

> edit applies to the current seoection, so if you want to do a global search and replace you need
> 
> 	Edit ,s:foo:bar:g

I’d like to look this up; is this a sam feature or an acme Edit one?

--Joel



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [9fans] Really basic acme Edit question
  2006-10-22  5:08 Joel chesky Salomon
  2006-10-22  5:27 ` andrey mirtchovski
@ 2006-10-22 14:38 ` erik quanstrom
  2006-10-22 19:00   ` Joel Salomon
  1 sibling, 1 reply; 8+ messages in thread
From: erik quanstrom @ 2006-10-22 14:38 UTC (permalink / raw)
  To: 9fans

edit applies to the current seoection, so if you want to do a global search and replace you need

	Edit ,s:foo:bar:g

you don't need SREs for something like this.

- erik
'
On Sun Oct 22 01:20:27 EDT 2006, chesky@plan9.jp wrote:
> What are the steps to use the Edit command?  I’ve been trying something really simple—changing every occurence of ‘foo’ to ‘bar’— and can’t seem to make it work.  I have some variation of
> 	Edit s/foo/bar/
> in the window’s tag, middle-select the whole thing, and get an error message saying “Edit: no substitution”.  And this is after reading the manuals and /sys/doc/ papers on both acme and sam; I just don’t get it. ☹


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [9fans] Really basic acme Edit question
  2006-10-22  5:08 Joel chesky Salomon
@ 2006-10-22  5:27 ` andrey mirtchovski
  2006-10-22 14:38 ` erik quanstrom
  1 sibling, 0 replies; 8+ messages in thread
From: andrey mirtchovski @ 2006-10-22  5:27 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

commands in 'Edit' apply to selected text (dot) just like Look or |


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [9fans] Really basic acme Edit question
@ 2006-10-22  5:08 Joel chesky Salomon
  2006-10-22  5:27 ` andrey mirtchovski
  2006-10-22 14:38 ` erik quanstrom
  0 siblings, 2 replies; 8+ messages in thread
From: Joel chesky Salomon @ 2006-10-22  5:08 UTC (permalink / raw)
  To: 9fans

What are the steps to use the Edit command?  I’ve been trying something really simple—changing every occurence of ‘foo’ to ‘bar’— and can’t seem to make it work.  I have some variation of
	Edit s/foo/bar/
in the window’s tag, middle-select the whole thing, and get an error message saying “Edit: no substitution”.  And this is after reading the manuals and /sys/doc/ papers on both acme and sam; I just don’t get it. ☹

--Joel



^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2006-10-22 19:29 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-10-22  5:37 [9fans] Really basic acme Edit question Joel chesky Salomon
2006-10-22  7:47 ` Skip Tavakkolian
2006-10-22 13:44   ` Joel Salomon
  -- strict thread matches above, loose matches on Subject: below --
2006-10-22  5:08 Joel chesky Salomon
2006-10-22  5:27 ` andrey mirtchovski
2006-10-22 14:38 ` erik quanstrom
2006-10-22 19:00   ` Joel Salomon
2006-10-22 19:29     ` Russ Cox

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