9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
* [9fans] Script to apply Edit commands in acme
@ 2023-01-16  3:49 revrari
  2023-01-16  8:17 ` sirjofri
  0 siblings, 1 reply; 9+ messages in thread
From: revrari @ 2023-01-16  3:49 UTC (permalink / raw)
  To: 9fans

[-- Attachment #1: Type: text/plain, Size: 730 bytes --]

In sam I can create a script file consisting of a list of edit commands to apply to the document. I then invoke *,| ssam -f my_script *to apply it.
I would like to do something similar in acme.
For example, create a script with these two commands to cleanup whitespace:
Edit ,x/^ +/d
Edit ,x/ +$/d
I would like to know if such a script would require the regular #!/bin/rc heading, and how it would be invoked from within acme. I tried to do something in my scripts folder, but it did not work.


------------------------------------------
9fans: 9fans
Permalink: https://9fans.topicbox.com/groups/9fans/Taf408751bc6fb344-M3eb35eb0b706b85667532f19
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription

[-- Attachment #2: Type: text/html, Size: 1334 bytes --]

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

end of thread, other threads:[~2023-01-20 14:24 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-01-16  3:49 [9fans] Script to apply Edit commands in acme revrari
2023-01-16  8:17 ` sirjofri
2023-01-16  9:06   ` revrari
2023-01-18 16:44     ` Henri Ducrocq
2023-01-18 16:54       ` Paul Lalonde
2023-01-19  9:33         ` revrari
2023-01-20  5:25           ` Ben Hancock
2023-01-20  7:23             ` igor
2023-01-20 14:24               ` Ben Hancock

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