From mboxrd@z Thu Jan 1 00:00:00 1970 Mime-Version: 1.0 (Apple Message framework v752.2) In-Reply-To: <88a477560610310922j6c5ed52dg6327ab6587479977@mail.gmail.com> References: <88a477560610310922j6c5ed52dg6327ab6587479977@mail.gmail.com> Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: <19DE8459-C68C-4B7C-9686-0EA1F6005DBD@telus.net> Content-Transfer-Encoding: 7bit From: Paul Lalonde Subject: Re: [9fans] winclear in p9p Date: Tue, 31 Oct 2006 10:06:02 -0800 To: Fans of the OS Plan 9 from Bell Labs <9fans@cse.psu.edu> Topicbox-Message-UUID: d97badc8-ead1-11e9-9d60-3106f5b1d025 -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Looking at this briefly, I discovered that the p9p version of acme doesn't make available body/addr/ctl/event of the current selected window. So the straightforward "substitute 9p commands" fails. What is the correct way for a script to discover the ID of the acme window it was run from? I could trap the command in the plumber and add the id as a parameter, but that's rather intrusive. Paul On 31-Oct-06, at 9:22 AM, Matthias Teege wrote: > Moin, > > I've found > > fn winclear { > echo -n Edit ,d > /dev/acme/body > echo -n /Edit ,d/ > /dev/acme/addr > echo -n 'dot=addr' > /dev/acme/ctl > cat /dev/acme/addr | awk '{printf("MX%s %s\n", $1, $2)}' > /dev/ > acme/event > } > > in the wiki but how do I clear a win in Plan 9 ports? To be accurate I > need to replace some text in the middle of the body and it would be > nice, if I can avoid a tempfile. > > Many thanks > Matthias -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.1 (Darwin) iD8DBQFFR5CLpJeHo/Fbu1wRAqS+AKCvwJhWvDn5Z+Yenu8NHEqv1h0WNQCeOzyC 1nvalZ6Jy7nFD3jnzAsz/BY= =w0ot -----END PGP SIGNATURE-----