[9fans] How to do this with [acme | sam | sed ] ?

2013-01-11 Thread Peter A. Cejchan
## How to do this with [acme | sam | sed ] ? # compound commands # remove outermost pair of braces: abcd(x+(y-z))efgh -- abcdx+(y-z)efgh [ no idea :-( ] # remove semicolon before // comments: xyz;[tab][space]*// -- xyz [ Edit /;[ ]*\/\// Edit s/;// # find and remove

Re: [9fans] How to do this with [acme | sam | sed ] ?

2013-01-11 Thread Rudolf Sykora
On 11 January 2013 12:19, Peter A. Cejchan tyap...@gmail.com wrote: # remove outermost pair of braces: abcd(x+(y-z))efgh -- abcdx+(y-z)efgh This, I believe, can't be achieved only with regexps. I'd write a small external program and use it as a filter. # prefix to postfix operator: ++i --

Re: [9fans] How to do this with [acme | sam | sed ] ?

2013-01-11 Thread Bence Fábián
for the third: /\+\+[a-zA-Z_]+[0-9a-zA-Z_]*/{ x/\+\+/d a/++/ } the braces stuff is pretty tough, but maybe someone will have an idea. however it is really easy to do it by hand in acme. click on the inside of the opening paren with a double click then click button 2 (while still holding down

Re: [9fans] How to do this with [acme | sam | sed ] ?

2013-01-11 Thread Peter A. Cejchan
how it come i didn't realize that ;-) ! thanks, peter On Fri, Jan 11, 2013 at 12:46 PM, Bence Fábián beg...@gmail.com wrote: for the third: /\+\+[a-zA-Z_]+[0-9a-zA-Z_]*/{ x/\+\+/d a/++/ } the braces stuff is pretty tough, but maybe someone will have an idea. however it is really easy to

Re: [9fans] How to do this with [acme | sam | sed ] ?

2013-01-11 Thread Nicolas Bercher
On 11/01/2013 12:19, Peter A. Cejchan wrote: ## How to do this with [acme | sam | sed ] ? # compound commands # remove outermost pair of braces: abcd(x+(y-z))efgh -- abcdx+(y-z)efgh [ no idea :-( ] Is this enough? echo 'abcd(x+(y-z))efgh' | sed 's;\(;;' | sed 's;(.*)\);\1;'

Re: [9fans] How to do this with [acme | sam | sed ] ?

2013-01-11 Thread dexen deVries
On Friday 11 of January 2013 13:24:12 Peter A. Cejchan wrote: I am now on p9p and this does not work - at least with (... )* using the \1 (used to be undocumented on plan9) may be sometimes easier Edit s/\+\+([A-Za-z]+[A-Za-z0-9])*/\1++/ oughta be Edit s/\+\+([A-Za-z]+[A-Za-z0-9]*)/\1++/

Re: [9fans] How to do this with [acme | sam | sed ] ?

2013-01-11 Thread Nicolas Bercher
On 11/01/2013 14:10, Peter A. Cejchan wrote: echo 'abcd(x+(y-z))efgh' | sed 's;\(;;' | sed 's;(.*)\);\1;' Thanks, this is fine for my purpose (porting from C to Go), thanks! Just removing parens around for and if statements on a single line. | 9 sed 's/\(//; s/(.*)\)/\1/' (linux's

Re: [9fans] How to do this with [acme | sam | sed ] ?

2013-01-11 Thread erik quanstrom
# remove outermost pair of braces: abcd(x+(y-z))efgh -- abcdx+(y-z)efgh [ no idea :-( ] this is made simple since * is greedy: Edit s:\((.*)\):\1:g On Fri Jan 11 06:45:39 EST 2013, rudolf.syk...@gmail.com wrote: On 11 January 2013 12:19, Peter A. Cejchan tyap...@gmail.com wrote:

Re: [9fans] How to do this with [acme | sam | sed ] ?

2013-01-11 Thread Rudolf Sykora
On 11 January 2013 15:24, erik quanstrom quans...@quanstro.net wrote: # remove outermost pair of braces: abcd(x+(y-z))efgh -- abcdx+(y-z)efgh [ no idea :-( ] this is made simple since * is greedy: Edit s:\((.*)\):\1:g Sure, this (the greediness) basically already stands behind

[9fans] a disk filesystem for both Plan 9 and Linux?

2013-01-11 Thread John Floren
I'd like to be able to use a disk in both Plan 9 and Linux. FAT seems to have some issues with sufficiently large partitions, so that's out. Plan9Port doesn't have fossil in the repo, although I've found patches. ext2srv may be an option, but I have no idea how reliable it would actually be. Am I

Re: [9fans] a disk filesystem for both Plan 9 and Linux?

2013-01-11 Thread Sergey Zhilkin
Hi ! It's useless, even from contrib/iru 2013/1/11 John Floren j...@jfloren.net I'd like to be able to use a disk in both Plan 9 and Linux. FAT seems to have some issues with sufficiently large partitions, so that's out. Plan9Port doesn't have fossil in the repo, although I've found

[9fans] u.h ape

2013-01-11 Thread Jeff Sickel
Can someone enlighten me about the history of /$objtype/include/u.h and why APE chose to do /sys/include/ape/u.h? There are a few cases where getting specific Plan 9 libraries massaged enough to be used from APE source gets to be a little more awkward because u.h is not architecture

Re: [9fans] u.h ape

2013-01-11 Thread Steve Simon
/sys/include/ape/u.h I have a distant memory that this was a result of Andrey and Presotto's work to get links to build and run on plan9. -Steve

Re: [9fans] a disk filesystem for both Plan 9 and Linux?

2013-01-11 Thread cinap_lenrek
i think fat is still the best option, even tho it has these limitations. virtually every operating system can deal with fat, and the implementations are robust and tolerant to errors because they are pretty much expected. ext2srv doesnt support jurnaling. -- cinap

Re: [9fans] a disk filesystem for both Plan 9 and Linux?

2013-01-11 Thread John Floren
On Fri, Jan 11, 2013 at 3:24 PM, cinap_len...@gmx.de wrote: i think fat is still the best option, even tho it has these limitations. virtually every operating system can deal with fat, and the implementations are robust and tolerant to errors because they are pretty much expected. ext2srv

Re: [9fans] a disk filesystem for both Plan 9 and Linux?

2013-01-11 Thread cinap_lenrek
dossrv always had fat32 support. you'r probably refering to disk/format, 9bootfat and pbs which do support fat32 now in 9front. -- cinap

Re: [9fans] a disk filesystem for both Plan 9 and Linux?

2013-01-11 Thread John Floren
On Fri, Jan 11, 2013 at 3:52 PM, cinap_len...@gmx.de wrote: dossrv always had fat32 support. you'r probably refering to disk/format, 9bootfat and pbs which do support fat32 now in 9front. -- cinap Thanks, you're entirely right, I was thinking of disk/format. john

Re: [9fans] a disk filesystem for both Plan 9 and Linux?

2013-01-11 Thread Bruce Ellis
I noticed the other day that I was offered exFAT when formatting a 2T drive on windows 7. I know nothing about it except the sample space of reading one page on the web. Any insights? Is this FAT48 or something newish and compatible in some transfinite sense. brucee On 12 January 2013 10:58,

Re: [9fans] a disk filesystem for both Plan 9 and Linux?

2013-01-11 Thread cinap_lenrek
from the wikipedia article: http://en.wikipedia.org/wiki/ExFAT Microsoft has not released the official exFAT file system specification, and a restrictive license from Microsoft is required in order to make and distribute exFAT implementations. Microsoft also asserts patents on exFAT which make

Re: [9fans] a disk filesystem for both Plan 9 and Linux?

2013-01-11 Thread Iruatã Souza
If you ever mount an extN partition with ext2fs, always remember to unmount it before reboot/shutdown. I remember having trouble with that. On Fri, Jan 11, 2013 at 4:58 PM, John Floren j...@jfloren.net wrote: I'd like to be able to use a disk in both Plan 9 and Linux. FAT seems to have some