From mboxrd@z Thu Jan 1 00:00:00 1970 MIME-Version: 1.0 In-Reply-To: References: Date: Tue, 3 Mar 2009 17:25:52 +0100 Message-ID: From: Rudolf Sykora To: Fans of the OS Plan 9 from Bell Labs <9fans@9fans.net> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Subject: Re: [9fans] command repetition in sam/acme Topicbox-Message-UUID: acc63ab6-ead4-11e9-9d60-3106f5b1d025 Thanks for the suggestions. Basically you propose breaking the line into many lines, navigate using lines, edit, and then go back. That's possible and manageable. There is probably no need for having sth simple for this particular task, however, generally thinking about it, being able to repeat either a regex or a command known number of times might be quite useful for me. (Then the task would be trivial.) Thanks Ruda PS.: Btw., as I said some time ago, files like mine do appear really often in any (perhaps non-computer) science --- physics, medecine, biology... There it is not so weird, but a necessity. > Or you could also substitute the newline for whatever you want, so you > don't have to copy/paste to another window, eg: > > Edit ,x/[\n]+/a/ENDOFLINE/ > Edit ,x/[ =A0 =A0 =A0 ]+/a/\n/ > > Now you can go to the 1000 word with > :/ENDOFLINE/+1000 > > and once you are done: > Edit ,x/\n/d > Edit ,x/ENDOFLINE/c/\n/ > > If you are sure you don't have blank fields you don't need ENDOFLINE > and can use ^$ instead (don't forget to use the g command when you > remove the new lines). A bit awkward, but I don't think there is > (there should be?) a simple way to do such a weird task. > > hth,