Re: [9fans] read9pmsg usage

2015-08-12 Thread David du Colombier
> Ah, if only git existed when that comment was written! :-D This comment is indeed pretty old. It was already present in the Second Edition. -- David du Colombier

[9fans] p9p sed vs linux sed

2015-08-12 Thread Rudolf Sykora
Hello, is this as expected? perseus=; echo -n aaa | 9 sed 's/^/

Re: [9fans] p9p sed vs linux sed

2015-08-12 Thread Ingo Krabbe
You mean perseus=; is your prompt? Strange. Actually sed is a line based command and should add a newline, imho. You can simply use tr -d '\n'. There are several quoting differences between plan9 sed and linux sed and I think the \+ operator doesn't work anyway in linux sed, but I might be wron

Re: [9fans] p9p sed vs linux sed

2015-08-12 Thread Rudolf Sykora
On 12 August 2015 at 09:48, Ingo Krabbe wrote: > You mean perseus=; is your prompt? Strange. Yes. perseus=; is the prompt. > Actually sed is a line based command and should add a newline, imho. I don't think it should add anything. For itself it should be able to count newlines (because of the

Re: [9fans] p9p sed vs linux sed

2015-08-12 Thread Ingo Krabbe
> You mean perseus=; is your prompt? Strange. > > Actually sed is a line based command and should add a newline, imho. You can > simply use tr -d '\n'. > > There are several quoting differences between plan9 sed and linux sed and I > think the \+ operator doesn't work anyway in linux sed, but I

Re: [9fans] p9p sed vs linux sed

2015-08-12 Thread tlaronde
On Wed, Aug 12, 2015 at 09:57:18AM +0200, Rudolf Sykora wrote: > On 12 August 2015 at 09:48, Ingo Krabbe wrote: > > > Actually sed is a line based command and should add a newline, imho. > > I don't think it should add anything. For itself it should be able to count > newlines (because of the po

Re: [9fans] p9p sed vs linux sed

2015-08-12 Thread Rudolf Sykora
> From the POSIX description (used here as some reference), when a > line is entered in the pattern space, the trailing new line is > discarded. When the pattern space is written to stdout it seems > that implicitely the new line is restored---the POSIX description > says that the input shall be a

Re: [9fans] read9pmsg usage

2015-08-12 Thread Giacomo Tesio
2015-08-12 9:25 GMT+02:00 David du Colombier <0in...@gmail.com>: > This comment is indeed pretty old. It was already present > in the Second Edition. > So that check is based on pre 9p2000 code? If so, Charles have probably explained it: 2015-08-10 17:40 GMT+02:00 Charles Forsyth : > As a furth

Re: [9fans] p9p sed vs linux sed

2015-08-12 Thread Ingo Krabbe
Luckily plan9 is not POSIX and actually sed does not really add a newline character, it just puts a newline to the end of each pattern buffer, that is done line-wise anyway. Also sed's little brother ed behaves the same, which makes the behaviour even more convenient term% echo -n 'abc' > inp

Re: [9fans] p9p sed vs linux sed

2015-08-12 Thread Rudolf Sykora
On 12 August 2015 at 13:35, Ingo Krabbe wrote: > Luckily plan9 is not POSIX and actually sed does not really add a > newline character, it just puts a newline to the end of each pattern > buffer, that is done line-wise anyway. Also sed's little brother ed > behaves the same, which makes the behavi

Re: [9fans] p9p sed vs linux sed

2015-08-12 Thread lucio
> this, in my opinion, only complicates things. You can't write a file in vi that does not end in a newline. I never found that problematic, even though sometimes one might wish to be able to overrule vi. So, I vote that text handling utilities should deal with all lines in text files uniformly,

Re: [9fans] p9p sed vs linux sed

2015-08-12 Thread Ingo Krabbe
> | sed 's/^//' > Why would you pipe text data in acme through sed and not use Edit x/^.*$/s/.*/<&>/ ?

Re: [9fans] p9p sed vs linux sed

2015-08-12 Thread Rudolf Sykora
On 12 August 2015 at 15:47, wrote: > You can't write a file in vi that does not end in a newline. You, however, can do it pretty easily with cat. (Sam asks you if you mean it, acme just does it.) > So, I vote that text handling utilities should deal with all lines in > text files uniformly,even

Re: [9fans] read9pmsg usage

2015-08-12 Thread Charles Forsyth
On 12 August 2015 at 10:18, Giacomo Tesio wrote: > So, seem that ignoring zeros is simply wrong. A residual from the past... There doesn't seem to be any justification for it now, whatever the original problem. Even if there were something, I'd fix that instead of ignoring the convention.

Re: [9fans] Small Plan 9 Platforms

2015-08-12 Thread Brian L. Stuart
On Wed, 8/12/15, David du Colombier <0in...@gmail.com> wrote: > > Is all that on sources somewhere or accessible otherwise? > > Richard's latest Raspberry Pi repository is available here: > > /n/sources/contrib/miller/9/bcm Cool. Somehow I missed that. I'll pull it and play with it. Using the

Re: [9fans] Small Plan 9 Platforms

2015-08-12 Thread Skip Tavakkolian
> On Wed, 8/12/15, David du Colombier <0in...@gmail.com> wrote: >> > Is all that on sources somewhere or accessible otherwise? >> >> Richard's latest Raspberry Pi repository is available here: >> >> /n/sources/contrib/miller/9/bcm > > Cool. Somehow I missed that. I'll pull it and play with it.

Re: [9fans] Small Plan 9 Platforms

2015-08-12 Thread Brian L. Stuart
On Wed, 8/12/15, Skip Tavakkolian <9...@9netics.com> wrote: > the gpio pins don't seem accessible through a filesystem api > like i see in plan9-bcm (unless i've missed something). I'm pretty sure it's not there. >  it would be great to merge that capability in. I've made a start on that this af