Re: [9fans] native lbl, long text in troff, bold italics in eqn

2010-09-03 Thread Pietro Gagliardi

On Sep 3, 2010, at 11:16 AM, Rudolf Sykora wrote:

3) Although eqn produces worse result than TeX, I like the way
formulae are input, and thus have used it. Sometimes I need bold
italics, which I achieve by overstriking. This isn't ideal, maybe
using a special bold italics font would be better. Has anyone thought
about this?

You should be able to embed troff directives in eqn:
f( \f(BIx\fP ) = 4 sin \f(BIy\fP
worked for me.




Re: [9fans] xml

2010-06-30 Thread Pietro Gagliardi

On Jun 30, 2010, at 2:43 PM, ron minnich wrote:

as long as you don't care about the (observed) 100:1 ratio of XML glop
to data in, e.g., the Python XMLRPC stuff, it's great. Yep, I observed
that ratio when Xen made the cut to XML-RPC: 3000 bytes of RPC to send
30 bytes of data. It's impressive: gigE gets reduced to 10 Mb ethernet
in no time; XML-RPC turns the network clock back by 20 years.


A friend on AIM who I showed this quote to suggested XML should drop  
named close tags as a solution: tagstuff/


C and Ratfor programmers find BEGIN and END bulky compared to  
{ and }. - bwk




Re: [9fans] problems with tracing 9vx on os x (was: Re: ghostscript not finding LucidaSans

2010-06-29 Thread Pietro Gagliardi

On Jun 29, 2010, at 4:03 AM, yy wrote:

By the way, you should be able to deactivate compilation of the tap
(or pcap) ether device with the variable PLAN9TAP (PLAN9PCAP) in
Makefrag.


Okay, I did so but I still get the crash as before. Here's a gdb  
backtrace:


#0  0x919366fa in select$DARWIN_EXTSN ()
#1  0xfc75 in microdelay (x=100) at 9vx/time.c:389
#2  0xdb9c in dt_panic (fmt=0xbd5cc user fault: signo=%d addr=%p  
[useraddr=%p] read=%d eip=%p esp=%p) at 9vx/stub.c:536
#3  0xa886 in sigsegv (signo=10, info=0x5e1fc0, v=0x5e1d20) at 9vx/ 
main.c:844
#4  0x00013b5c in wrapper (siginfo=0x5e1fc0, mcontext=0x5e1d60,  
handler=0xa769 sigsegv) at 9vx/osx/signal.c:85

#5  0x000b6e09 in xscan (p=0x63f3a0) at libvx32/emu.c:247
#6  0x000b9bda in xlate (vxp=0x63f3a0) at libvx32/emu.c:1695
#7  0x000b9e7e in vxproc_run (vxp=0x63f3a0) at libvx32/emu.c:1841
#8  0x0001373f in touser (initsp=0xfa4) at 9vx/vx32.c:251
#9  0xa762 in init0 () at 9vx/main.c:742

I'm not sure what this information would give you, but...



Re: [9fans] megamouse?

2010-06-29 Thread Pietro Gagliardi

On Jun 29, 2010, at 7:11 PM, John Floren wrote:

Hey, there's a way to end the mouse/keyboard switching argument once
and for all! With 18 buttons, you can just make the mouse a chording
keyboard as well and never move your hand from the mouse.


Amputees around the world jump for joy.

Also as a side note, this was originally known as the OpenOffice.org  
Mouse. Hey! Let's make an acme/Wily Mouse; it'd totally sell!




Re: [9fans] ghostscript not finding LucidaSans

2010-06-28 Thread Pietro Gagliardi

On Jun 28, 2010, at 12:40 AM, erik quanstrom wrote:

guess i forgot the bind /tmp /sys/lib/lp/tmp.  lp is
pretty complicated.

- erik



Thanks, now it worked. I decided to investigate the issue further with  
what you gave me and I found that all I needed to get it to work was the

bind /n/sources/plan9/sys /sys
and further constrained that to
bind /n/sources/plan9/sys/lib/postscript/ /sys/lib/postscript/
However, overwriting my /sys/lib/postscript with the one from sources  
did not fix the problem. Is there some fundamental difference between  
binding and copying that I'm overlooking or just some weird behavior  
in ghostscript that is causing this to happen?


The diff output from comparing the two directories:

diff /sys/lib/postscript//troff/HX /n/sources/plan9/sys/lib/ 
postscript//troff/HX

1c1
 0x 0x00ff Helvetica-Narrow-BoldOblique
---
 0x 0x00ff Helvetica-BoldOblique
Only in /n/sources/plan9/sys/lib/postscript//troff: Hx




Re: [9fans] ghostscript not finding LucidaSans

2010-06-28 Thread Pietro Gagliardi
Actually, on further investigation it turns out while dircp /n/sources/ 
plan9/sys/lib/postscript dir works fine, diff -r dir /n/sources/plan9/ 
sys/lib/postscript gives me the same diff log, and diff -r dir olddir  
tells me they're identical. So what's going on here...




Re: [9fans] ghostscript not finding LucidaSans

2010-06-28 Thread Pietro Gagliardi

On Jun 28, 2010, at 9:09 AM, erik quanstrom wrote:


On Mon Jun 28 02:37:21 EDT 2010, pietr...@mac.com wrote:
Actually, on further investigation it turns out while dircp /n/ 
sources/
plan9/sys/lib/postscript dir works fine, diff -r dir /n/sources/ 
plan9/

sys/lib/postscript gives me the same diff log, and diff -r dir olddir
tells me they're identical. So what's going on here...


the difference that i can think of is #Z.  #Z doesn't do
locks, exclusive access, etc.  why don't you try binding a ramfs
/tmp on lp's temp directory, /sys/lib/lp/tmp.  if that's not
it, the bind/mount list you used to get things working from
sources should give you more directories to investigate.

- erik



That didn't work. I narrowed the directory discrepancies to /sys/lib/ 
postscript/font but not to any of its subdirectories. However again,  
copying from sources and overwriting what's already there did nothing,  
even if I had removed the directory from the host machine already. I  
also tried to overwrite with a copy of the directory tree from an ISO  
downloaded today, but that didn't work either (however both ISOs  
appear to come from June 26, so I dunno). Only binding did the trick.





[9fans] problems with tracing 9vx on os x (was: Re: ghostscript not finding LucidaSans

2010-06-28 Thread Pietro Gagliardi

On Jun 28, 2010, at 11:04 AM, ron minnich wrote:

well, once again, ratrace can be a good tool for understanding things
that don't make sense. I use it all the time for this type of problem
and the results are frequently illuminating.

ron




First I found a slight building problem on Mac OS X 10.5.8: ethertap.c  
needs to be changed to include sys/socket.h before net/if.h and to  
add a defined(__MACOSX__) or similar to the #elf defined(__FreeBSD__)  
so opentap() can be defined.


However once this version was built, I got the following right after  
seeing the memory usage statistic line:


9vx panic: user fault: signo=10 addr=1100cc77 [useraddr=cc77] read=1  
eip=b7de5 esp=2e93ece0

sleeping, so you can attach gdb to pid 44257




[9fans] ghostscript not finding LucidaSans

2010-06-27 Thread Pietro Gagliardi
From an install to 9vx (built from mercurial on OS X 10.5.8) from  
yesterday's CD image (though apparently some people on IRC have this  
problem too):


term% man -P man
converting from troff to postscript...
reading through postscript...
Ghostscript Error:
postnote 307: sys: write on closed pipe pc=0x0001f8fc
Fontmap entry for LucidaSans ends prematurely!  Giving up.
converting from troff to postscript...
reading through postscript...
Ghostscript Error:
postnote 358: sys: write on closed pipe pc=0x0001f8fc
Fontmap entry for LucidaSans ends prematurely!  Giving up.
term% troff | page # let's try without referencing LucidaSans at all
Hello
(^d)converting from troff to postscript...
reading through postscript...
Ghostscript Error:
postnote 404: sys: write on closed pipe pc=0x0001f8fc
Fontmap entry for LucidaSans ends prematurely!  Giving up.

I don't understand what's going on here but as far as I can tell /sys/ 
lib/postscript/fonts/LucidaSans has never existed in the Plan 9  
directory tree (checking sourcesdump) and my old VM works fine without  
it. Anyone know what's going on here? Thanks.





Re: [9fans] ghostscript not finding LucidaSans

2010-06-27 Thread Pietro Gagliardi

On Jun 27, 2010, at 9:56 PM, erik quanstrom wrote:

i can't reproduce your results:

Huh. Using your suggested command line I get the following:

converting from troff to postscript...
/tmp/lp174: rc (generic): can't open: '/tmp/lp174' permission denied
reading through postscript...
cannot find end of first line

I'm not sure if this has to do with 9vx... in fact I'm not sure  
exactly what's causing these things to behave as they are now. What I  
can say is that to set this environment up I just copied the contents  
of the Plan 9 CD to a folder, put the built-from-source 9vx into that  
folder, logged in as glenda, ran

mkdir /usr/pietro
(since fscons obviously isn't there), logged in as pietro, and ran
/sys/lib/newuser




[9fans] Rails? (was Re: web server)

2009-04-16 Thread Pietro Gagliardi

Just a thought.

Is Rails even necessary? Other server-side alternatives do exist, and  
they can be written. IIRC, the author of rit mentioned it being used  
in his Pegasus server...





Re: [9fans] Rails? (was Re: web server)

2009-04-16 Thread Pietro Gagliardi

On Apr 16, 2009, at 1:50 PM, Devon H. O'Dell wrote:


MVC development model


Good point. I think I'll get started porting Cocoa to Plan 9. =P




Re: [9fans] Help for home user discovering Plan 9

2009-04-14 Thread Pietro Gagliardi
Plan 9 in the home... an interesting experiment. (I am the only one in  
my home who uses it.) Enjoy!


My message contains references to files in /n/sources/contrib. When  
you get your internet up in Plan 9, use


9fs sources

to gain access to this folder. PostScript and PDF files can be seen  
with page. If a program is distributed as source code and a file  
mkfile, type


mk install

to build and install. Some of us have switched to Federico Benavento's  
contrib system. To install it, run


/n/sources/contrib/fgb/root/rc/bin/contrib/install fgb/contrib

On Apr 14, 2009, at 2:05 AM, Jim Habegger wrote:


Meanwhile, does anyone have
any suggestions about learning to use Plan 9 for home office,


troff for document processing and presentations. A troff document is a  
text file containing text and commands, like so:


.PP
Hey there!
This is troff.
.B I have bold text .

The main troff documentation is /sys/doc/troff.ps, but a tutorial is a  
better bet. Take a look at http://www.troff.org/papers.html.


To integrate a picture, you will first need to convert that picture  
file into a postscript file:

lp -dstdout -pgifpost file.gif  file.ps
lp -dstdout -pjpgpost file.jpg  file.ps
Then look up the mpictures macro set. You can have more than one macro  
set:

troff -ms -mpictures cool.ms

Converting to PDF:
troff -ms -mpictures cool.ms | dpost -f | ps2pdf  cool.pdf

There are several specialized slideshow packages.
	* the archaic mv macro set included with Plan 9 (doc: /n/sources/ 
contrib/pietro/mv.pdf).

* Uriel's slides scripts (/n/sources/contrib/uriel/slides/)
* Russ Cox's talk scripts (/n/sources/contrib/rsc/talk/)

Plan 9 doesn't have:


multimedia


Each picture type has a program for viewing it, named after the file  
extension (png, jpg, etc.); page can be used to view multiple pictures  
at once.


juke(6) for how to go about playing music.

I don't think there are video players.


and Internet socializing,


There are IRC clients in /n/sources/contrib and an AIM client at /n/ 
sources/contrib/leitec/bsflite/. I don't think you can use websites  
with Plan 9 unless everything is done server-side. The primary web  
browser is abaco:


contrib/install fgb/abaco


and then to learn more about
networking and distributed systems?


Read the files in /sys/doc.




Re: [9fans] Help for home user discovering Plan 9

2009-04-14 Thread Pietro Gagliardi

On Apr 14, 2009, at 8:36 AM, Pietro Gagliardi wrote:


juke(6) for how to go about playing music.

that should be juke(7), sorry.




Re: [9fans] GSOC: Drawterm for the iPhone

2009-03-26 Thread Pietro Gagliardi

On Mar 26, 2009, at 3:32 AM, André Günther wrote:


[1] http://www.minithink.org/mock.jpg
(Sorry for the image quality)


I just tried giving that to Interface Builder. Apparently, toolbars  
can only be on the horizontal in Cocoa Touch. But this is an  
interesting start.


The problem of how to make rio work on a small device still exists.  
How about replace rio with a two-fold environment:


1) Window Choosing/Managing. If you click a window, you can either  
bring it up or move/resize.
2) Window: When you choose to bring up a window, you can work in that  
window. There should be a Zoom/Pan button which will allow you to  
modify the area you work in for higher visibility in larger windows.




Re: [9fans] GSOC: Drawterm for the iPhone

2009-03-26 Thread Pietro Gagliardi

On Mar 26, 2009, at 3:35 PM, Eric Van Hensbergen wrote:


I'm merely trying to debunk roadblocks which others
seem to want to through in his way.


I don't want to throw a roadblock in this student's way. (In fact,  
drawterm on iPhone benefits me too, though that benefit would come in  
or after June :-| ) I just tried to point out a few hurdles. That's  
what design and development is for: jumping hurdles.


On Mar 26, 2009, at 2:50 PM, andrey mirtchovski wrote:

a straight cocoa drawterm rewrite

On Mar 26, 2009, at 3:00 PM, Uriel wrote:

A 9vx, p9p or inferno cocoa port is a project that seems fairly


I can do one of these; which is the most needed/wanted?




Re: [9fans] GSOC: Drawterm for the iPhone

2009-03-25 Thread Pietro Gagliardi
Killed. From the license agreement for iPhone developers (which  
requires a free Apple Developer Connection account to view; sorry):


3.3.3 Without Apple’s prior written approval, an Application may not  
provide, unlock or enable a enable additional features or  
functionality through distribution mechanisms other than the App Store.


drawterm may be used to gain access to a large repository of optional  
software (/n/sources/contrib, /n/sources/extra).


An ill-informed lawyer may bring this up:

3.3.2 An Application may not itself install or launch other  
executable code by any means, including without limitation through the  
use of a plug-in architecture, calling other frameworks, other APIs or  
otherwise. No interpreted code may be downloaded and used in an  
Application except for code that is interpreted and run by Apple's  
Published APIs and built-in interpreter(s).


This is a shaky one. While drawterm does not itself run code, it  
allows you to connect to a computer that runs its own programs.


But even if we did overcome all this...

We have scribble, and rio is optional, so I don't think input is too  
much of a problem. A pain, yes, but not a problem.


How about determining button 1, 2, 3? Triple-touch? You might get  
tired too easily.





Re: [9fans] GSOC: Drawterm for the iPhone

2009-03-25 Thread Pietro Gagliardi
Also, we obviously cannot use rio, unless we greatly restrict the  
user's visibility. Unless we provide zooming?


Maybe a text-based environment that runs exclusively off rc, sam,  
acme, etc. with the standard keyboard at the bottom:


Exitdrawterm  Commands
--
cpu% cat message
this is a message
cpu% cp message /mnt/term/whatever
cpu% cat /mnt/term/whatever/message
this is a message
cpu% ftpfs -m/n/andlabs andlabs.com 
/dev/null
cpu% cp message /n/andlabs
--
(apple keyboard goes here)


Hitting the Commands button would yield a menu to the likes of the rio  
Button 2 menu (cut, paste, snarf, plumb, send).





Re: [9fans] plot cmd dotted dashed lines not implemented??

2009-02-24 Thread Pietro Gagliardi

On Feb 24, 2009, at 5:49 PM, Fernan Bolando wrote:


not sure where USED(s); is implemented.


It tells the compiler not to print the warning

s: set but not used




Re: [9fans] plot cmd dotted dashed lines not implemented??

2009-02-24 Thread Pietro Gagliardi
Styles aren't in the libplot that plot uses as an engine. I can add  
them in the next few days if you want.


On Feb 24, 2009, at 5:59 PM, erik quanstrom wrote:


Sorry Erik I dont particuarly understand your reply
I am guessing that it's referring to pe working for  lines only.


it only claims to work for lines.  evidently it does not
work at all.


#include mplot.h
void pen(char *s){
/* BUG: NO OP */
USED(s);
/* was this error:  color(s); */
}

not sure where USED(s); is implemented.


USED is implemented by the c compiler. the syntax
is USED(var, ...).  it doesn't do anything but supress
unused variable warnings.

a more natural implementation with kenc would be

void
pen(char*)
{
/* bug: noop */
}

- erik






Re: [9fans] with reference to the earlier plan 9 interns post

2009-02-13 Thread Pietro Gagliardi

I am a high school student and have a GPA; I know it's higher than 3.2.
What are the requirements for Murray Hill?

On Feb 13, 2009, at 6:46 PM, jimmy brisson wrote:


On Fri, Feb 13, 2009 at 11:12 PM, Akshat Kumar
aku...@mail.nanosouffle.net wrote:

What Plan 9 user has a GPA at all?
ak


-- Forwarded message --
From: ron minnich rminn...@gmail.com
To: Fans of the OS Plan 9 from Bell Labs 9fans@9fans.net
Date: Fri, 13 Feb 2009 09:20:20 -0800
Subject: [9fans] with reference to the earlier plan 9 interns post
there are also possibilities are murray hill and IBM.

You should check these other opportunities out too.

But, for all of us, if you want an internship, you really must be a
student. For sandia, there is also a minimum 3.2 GPA.

Here's the main sandia page:
http://www.sandia.gov/employment/special-prog/sip/undergrad.html
(links to grad and high school at top of page).

And, I'll say it again:
For Sandia, (1) must be US citizen, (2) Student (grad or undergrad or
high school) (3) 3.2 GPA

Thanks

ron




I am still in high school... (and my GPA is 3.5 I think)
I would apply if I did not alredy have a job this summer

-jimmy





Re: [9fans] Web interface to '/n/sources/contrib' gone??

2009-02-09 Thread Pietro Gagliardi

On Feb 9, 2009, at 5:09 AM, c...@gli.cas.cz wrote:



?
++pac




This is my only concern over the whole sources is gone thing; this  
time the web interface has been down for longer than usual (two weeks,  
maybe more?).




Re: [9fans] Web interface to '/n/sources/contrib' gone??

2009-02-09 Thread Pietro Gagliardi
I'm trying to transfer files from my Plan 9 virtual PC to Mac OS X for  
printing; QEMU has no USB yet and SAMBA fails on Mac OS X Leopard. I  
print on systems without plan9ports, and where I have no development  
tools (so I can't build it). Right now I've been using my FTP server,  
but it disconnects me after I access the PDF file, so I need to log on  
and delete it.


On Feb 9, 2009, at 11:04 PM, Bruce Ellis wrote:


9fs not good enough for you? what operating system are you using?

brucee

On Tue, Feb 10, 2009 at 5:26 AM, Nicola Gagliardi pietr...@mac.com  
wrote:
I'm talking about the web interface to /n/sources/contrib, which is http://plan9.bell-labs.com/sources/contrib/ 
. That has been down for two weeks.


On Monday, February 09, 2009, at 08:08AM, Bruce Ellis bruce.el...@gmail.com 
 wrote:
I will not comment - I've been asked to leave 95% boy alone.  
Certainly

works from Brazil. I downloaded a CD image just last night.

brucee

On Mon, Feb 9, 2009 at 11:52 PM, erik quanstrom quans...@quanstro.net 
 wrote:
This is my only concern over the whole sources is gone thing;  
this
time the web interface has been down for longer than usual (two  
weeks,

maybe more?).


not true.  i just tried it an http://plan9.bell-labs.com/plan9/
comes up instantly.  perhaps your machine is on the fritz?

- erik

















Re: [9fans] sed crash

2009-02-05 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

I misunderstood what they meant by debugging. PGP is doing nothing  
wrong; I thought there was debugging info in the email.


On Feb 5, 2009, at 8:16 AM, erik quanstrom wrote:



What do you mean? Could you paste the raw text data for one of my
emails? PGP for Mac Mail hides everything.



i considered adding code to upas to at least
strip pgp nonesense from message bodies.  but this
would require upas to know things about what
message bodies look like after mime is done with
them.  i thought that was a bad idea.  next we'll
be replacing :-) (':' '-' ')' for those with impaired
mail readers) with a jpeg.

- erik



-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkmLU9gACgkQuv7AVNQDs+xFiwCeJQOQC4pVv8sR5gFkEilI2tSP
O/gAoJNbwL5A0nBgd4182tT6GFXTsf+3
=hmuJ
-END PGP SIGNATURE-



Re: [9fans] sed crash

2009-02-04 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Feb 4, 2009, at 9:28 PM, Uriel wrote:


For those that enjoy fixing bugs:

% echo foo | sed
's/..a|..b|..c|..d|..e|..f|..g|..h|..i|..j|..k|..l|..m|..n|..o|..p//g'

Will crash both native and p9p sed.

Yes, I know it is a nonsensical expression, but it is the simplest one
that still made it crash, I have lost the original version which was
much more complex.

Note that providing two characters as input will still crash, but if
the input line is a single character it wont crash.

I have been meaning to get all the fun of tracking this one down
myself for a while, but seems that I never get to it, so I will let
others enjoy the fun of fixing it.

Peace

uriel

For me, it crashes on the second line of input, in the dosub()  
function. Will investigate now.

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkmKVgoACgkQuv7AVNQDs+x7ZACfYvtxSB5c8TD8LFFjPPHsgtah
9DwAnjIQ0GM4b82JGPpdJIUYfHjs7+Pv
=7lRk
-END PGP SIGNATURE-



Re: [9fans] sed crash

2009-02-04 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

lp = loc2;
loc2 = sp - genbuf + linebuf;
while(*sp++ = *lp++)

At the point of crash, loc2 is a null pointer when it is assigned to  
lp, so when the while() statement executes, crash. Now to find out why  
and when loc2 becomes null.


On Feb 4, 2009, at 9:59 PM, Pietro Gagliardi wrote:


-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Feb 4, 2009, at 9:28 PM, Uriel wrote:


For those that enjoy fixing bugs:

% echo foo | sed
's/..a|..b|..c|..d|..e|..f|..g|..h|..i|..j|..k|..l|..m|..n|..o|..p// 
g'


Will crash both native and p9p sed.

Yes, I know it is a nonsensical expression, but it is the simplest  
one

that still made it crash, I have lost the original version which was
much more complex.

Note that providing two characters as input will still crash, but if
the input line is a single character it wont crash.

I have been meaning to get all the fun of tracking this one down
myself for a while, but seems that I never get to it, so I will let
others enjoy the fun of fixing it.

Peace

uriel

For me, it crashes on the second line of input, in the dosub()  
function. Will investigate now.

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkmKVgoACgkQuv7AVNQDs+x7ZACfYvtxSB5c8TD8LFFjPPHsgtah
9DwAnjIQ0GM4b82JGPpdJIUYfHjs7+Pv
=7lRk
-END PGP SIGNATURE-



-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkmKWCEACgkQuv7AVNQDs+xSQQCgoFPwqMsaphtaKBTHHLFryiJr
eUMAnA9BjuDpMU40VqJp5hu1EDr3mdXp
=XF/E
-END PGP SIGNATURE-



Re: [9fans] sed crash

2009-02-04 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

The bug doesn't seem to be in sed. The match() function calls  
rregexec(), which sets a strucuture that is set to loc2, which is made  
null for some reason.


On Feb 4, 2009, at 10:08 PM, Pietro Gagliardi wrote:


-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

lp = loc2;
loc2 = sp - genbuf + linebuf;
while(*sp++ = *lp++)

At the point of crash, loc2 is a null pointer when it is assigned to  
lp, so when the while() statement executes, crash. Now to find out  
why and when loc2 becomes null.


On Feb 4, 2009, at 9:59 PM, Pietro Gagliardi wrote:


-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Feb 4, 2009, at 9:28 PM, Uriel wrote:


For those that enjoy fixing bugs:

% echo foo | sed
's 
/..a|..b|..c|..d|..e|..f|..g|..h|..i|..j|..k|..l|..m|..n|..o|..p//g'


Will crash both native and p9p sed.

Yes, I know it is a nonsensical expression, but it is the simplest  
one

that still made it crash, I have lost the original version which was
much more complex.

Note that providing two characters as input will still crash, but if
the input line is a single character it wont crash.

I have been meaning to get all the fun of tracking this one down
myself for a while, but seems that I never get to it, so I will let
others enjoy the fun of fixing it.

Peace

uriel

For me, it crashes on the second line of input, in the dosub()  
function. Will investigate now.

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkmKVgoACgkQuv7AVNQDs+x7ZACfYvtxSB5c8TD8LFFjPPHsgtah
9DwAnjIQ0GM4b82JGPpdJIUYfHjs7+Pv
=7lRk
-END PGP SIGNATURE-



-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkmKWCEACgkQuv7AVNQDs+xSQQCgoFPwqMsaphtaKBTHHLFryiJr
eUMAnA9BjuDpMU40VqJp5hu1EDr3mdXp
=XF/E
-END PGP SIGNATURE-



-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEUEARECAAYFAkmKYMwACgkQuv7AVNQDs+xcpACYi9wXYM/0ONUOOrqPJu4ViRFZ
BACfTLv0GRuZzUP/WYeU72Jm+KqDunw=
=Vrfb
-END PGP SIGNATURE-



Re: [9fans] sed crash

2009-02-04 Thread Pietro Gagliardi

On Feb 4, 2009, at 10:58 PM, andrey mirtchovski wrote:


also, can you please remove debugging output from 9fans?


What do you mean? Could you paste the raw text data for one of my  
emails? PGP for Mac Mail hides everything.




Re: [9fans] Flash Video

2009-02-03 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Feb 3, 2009, at 5:11 AM, Eris Discordia wrote:

I don't know of any open source implementations of Flash Player. The  
software on each platform and for each browser seems to be (c) Adobe  
and closed source. Does an open source implementation, however  
incomplete, exist?


The two major ones are swfdec and Gnash, the latter part of the GNU  
project. They're both at version 0.8.4, but swfdec 0.9.2 is available  
as development version.

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkmIKrkACgkQuv7AVNQDs+wJ+wCghd0KZynItmM56GgowKv7MxZq
XI0An03lZmRkM5PrQ1PjCY+EBlOwyRM5
=yeuI
-END PGP SIGNATURE-



Re: [9fans] Installation CD Problems

2009-01-31 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Jan 31, 2009, at 5:33 PM, erik quanstrom wrote:


if someone's itching for a project, the installer could use
a little touch up.


The program to detect where to install from, /sys/lib/dist/pc/inst/ 
mountdist, is good. The only problem seems to be with the plan9.ini  
file, /sys/lib/dist/pc/plan9.ini.cd, which specifically asks to boot  
from /dev/sdD0. Unless there is a better way to specify the device  
where plan9.ini was found, say $inidev? That would require some  
modifications to the plan9.ini parser, am I right?


However, Akshat also said

On Jan 31, 2009, at 1:52 PM, Akshat Kumar wrote:


However, booting into just the Install goes OK


but the plan9.ini.cd behaves the same way in Install as in Boot Live.  
Unless there's something I'm missing...


-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkmE1bAACgkQuv7AVNQDs+wS5gCfXAiX0cvYh66avVFuCQ1kwdhx
BTEAnA7acRmK+X/F5kw435BQVUeSbC/f
=zOym
-END PGP SIGNATURE-



Re: [9fans] Plan9 so much easier than...

2009-01-29 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Jan 29, 2009, at 3:04 PM, Randall Bohn wrote:


groff -man slig.8 wasn't readable.


How? I get PostScript output when running a similar thing. (Strange  
how groff automatically calls grops, but hey, that's GNU for you.)


-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEUEARECAAYFAkmCE58ACgkQuv7AVNQDs+yNRwCfdAFG686e9wppEWZgxMb4ApsQ
zJMAmLXTCpNc/2YLzGK74Wtmi5gQ53I=
=7K/8
-END PGP SIGNATURE-



[9fans] Spam and IMAP folders (was: Re: crypto for criminals)

2009-01-25 Thread Pietro Gagliardi
Been getting a lot of it recently. Since I'm on MobileMe, and upas  
doesn't have the folder indexing stuff that I'm looking for, I can't  
use it. Is there an alternative? If so, I'll see if your command set  
will work.


On Jan 25, 2009, at 8:38 PM, j...@csplan9.rit.edu wrote:


Criminals looking for encryption, to stop the PoPo
from snooping, need look no further.

http://www.CryptoSMS.org

It's free, it's secure, and best of all, Pigs can't break it.

--
How will we cope after Rashid endorses the universal interview's  
panic?


||upas/spam
d
q






PGP.sig
Description: This is a digitally signed message part


Re: [9fans] Small program PlanKey (paraphrase of DOSKey)

2009-01-23 Thread Pietro Gagliardi
This code is interesting. I do see one problem: commands that take up  
more than one line won't be stored in the history properly, so each  
line will get its own entry. But this is a nice use of pipes!


On Jan 23, 2009, at 5:03 AM, pavel.klinkov...@gmail.com wrote:


Hi all,

In Plan9 I missed the simple way to repeat previous (or previous of
previous etc.) command in the terminal.
I prepared a very small (an stupid) program to allow that.

Compile the following source code and run it in that way:
8.out | rc -i

You can insert the commands, and if you want to walk through the
history, just press CTRL+K (backward) or CTRL+L (foreward).

That is all, folks. ;-)

Pavel


#include u.h
#include libc.h

enum
{
KCtrlD = 0x04,
KCtrlK = 0x0B,
KCtrlL = 0x0C,
KDelete = 0x7F,

MaxLen = 128,
MaxDepth = 10
};

struct Line
{
int len;
char buf[MaxLen];
};
typedef struct Line Line;

void
main(void)
{
// Console control file descriptor
int cfd;
// End flag
int end = 0;
// Actual read character
char c;
// Array of BackSpaces
char bs[MaxLen];
// Array of Lines
Line line[MaxDepth];
// Index of actual line
int act = 0;
// Index of stored line
int stored = 0;

memset(bs, '\b', sizeof(bs));
memset(line, 0, sizeof(line));

cfd = open(/dev/consctl, OWRITE);
if (cfd  0)
sysfatal(%r);
write(cfd, rawon, 5);

while (!end) {
if (read(0, c, sizeof(c))  0)
sysfatal(%r);

switch (c) {
case KCtrlD:
case KDelete:
end++;
break;

case '\b':
if (line[act].len  0) {
line[act].len--;
write(2, c, sizeof(c));
}
break;

case '\n':
if (line[act].len  0)
write(1, line[act].buf, line[act].len);
write(1, c, sizeof(c));
write(2, c, sizeof(c));
act = stored = (act + 1) % MaxDepth;
line[act].len = 0;
break;

case KCtrlK:
write(2, bs, line[act].len);
stored = (stored + MaxDepth - 1) % MaxDepth;
line[act] = line[stored];
write(2, line[act].buf, line[act].len);
break;

case KCtrlL:
write(2, bs, line[act].len);
stored = (stored + 1) % MaxDepth;
line[act] = line[stored];
write(2, line[act].buf, line[act].len);
break;

case -0x11:
read(0, c, sizeof(c));
read(0, c, sizeof(c));
break;

default:
if (line[act].len  MaxLen) {
line[act].buf[line[act].len++] = c;
write(2, c, sizeof(c));
}
break;
}
}

close(cfd);

exits(nil);
}





PGP.sig
Description: This is a digitally signed message part


Re: [9fans] fun question

2009-01-22 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Jan 22, 2009, at 5:01 PM, Russ Cox wrote:

- is a unary operator.



okay, what does it do? (unless you meant - in C++)


-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkl47zYACgkQuv7AVNQDs+wr7ACgi7QtQv4m4TweJlyzLFSHUs41
ZCYAnR6CqXQp69/g99pUkI0W789SRxXF
=s97M
-END PGP SIGNATURE-



Re: [9fans] fun question

2009-01-22 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Jan 22, 2009, at 6:01 PM, erik quanstrom wrote:


i assumed that ron was talking about c.


Yeah, that's what I thought. Sorry, Russ.

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkl5E1IACgkQuv7AVNQDs+xctgCggzbkwZ8EpuuEPu7e5kgItuC5
vDgAnisvoB6CWTOrPaXQ04jqyRL2kuJV
=Yw+A
-END PGP SIGNATURE-



Re: [9fans] two quick questions on syscalls

2009-01-08 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Last time I checked, isn't _brk() still used by libc?

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAklmdo8ACgkQuv7AVNQDs+w5mQCfZRYkhc4CKRx/nBXL4tSfMNb4
Zu8An2NDriTCXhUnZJj5CGUd0iH7HzVw
=iWJP
-END PGP SIGNATURE-



[9fans] [possibly off-topic] something random I found a few months ago

2008-12-19 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

A portion of the Mac OS X cat manual page. This was back in July. I  
don't remember if this was while I had OS X 10.4 or 10.5. Either way,  
it's the same now (10.5.6).


	CAT(1)BSD General Commands  
Manual   CAT(1)


NAME
 cat -- concatenate and print files

SYNOPSIS
 cat [-benstuv] [-] [file ...]

...

SEE ALSO
 head(1), more(1), pr(1), tail(1), vis(1)

	 Rob Pike, UNIX Style, or cat -v Considered Harmful, USENIX  
Summer

 Conference Proceedings, 1983.

HISTORY
 A cat utility appeared in Version 6 ATT UNIX.

	3rd Berkeley Distribution May 2, 19953rd Berkeley  
Distribution


-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAklMMGYACgkQuv7AVNQDs+zkxQCbBbKrv9BemYfemXjkYUmtmAlA
/+0An0Ho72xd9xqveL/Bbv7H97tAZWzh
=annc
-END PGP SIGNATURE-



Re: [9fans] 9P in C++

2008-12-15 Thread Pietro Gagliardi

On Dec 15, 2008, at 10:45 AM, Rodolfo kix García wrote:


Hi!

I am working in an c++ application on linux and I would like to use a
filesystem to access to the application data.

Somebody knows any 9P implementation of 9P in C++?

Thanks,

Saludos, kix.


--
Rodolfo García AKA kix
http://www.kix.es/
EA4ERH (@IN80ER)




Given

extern C{
#include 9p.h // or whatever you do
}

you can link 9p into a C++ program easily.



PGP.sig
Description: This is a digitally signed message part


Re: [9fans] 9P in C++

2008-12-15 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Dec 15, 2008, at 6:25 PM, Rodolfo kix Garcia wrote:

gcc -L /usr/local/plan9/lib -L. -ltry -lthread demo1.C -o demo1  ##  
OK!


I think linking lthread will give you POSIX threads and that -L  
appends to the list, rather than going before, so /usr/lib will be  
searched before plan9ports. Try explicitly setting the path of the -l  
argument. Does -l/usr/local/plan9/lib/libthread.so (or whatever it is)  
help?


-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAklG6YAACgkQuv7AVNQDs+xs6QCfZy4CD480VMiv8DN2VyX2ydDs
WzYAn0sEgTbpQM9Z/8ieACzLVBx15okU
=Jzfc
-END PGP SIGNATURE-



Re: [9fans] 9P in C++

2008-12-15 Thread Pietro Gagliardi

On Dec 15, 2008, at 9:16 PM, sqweek wrote:

On Tue, Dec 16, 2008 at 8:34 AM, Pietro Gagliardi pietr...@mac.com  
wrote:

On Dec 15, 2008, at 6:25 PM, Rodolfo kix Garcia wrote:
gcc -L /usr/local/plan9/lib -L. -ltry -lthread demo1.C -o demo1   
## OK!


I think linking lthread will give you POSIX threads and that -L  
appends to
the list, rather than going before, so /usr/lib will be searched  
before

plan9ports. Try explicitly setting the path of the -l argument. Does
-l/usr/local/plan9/lib/libthread.so (or whatever it is) help?


You can't use -l with a full path, but you can simply specify the
full path of the library:
gcc -o demo1 demo1.C /usr/local/plan9/lib/libthread.a
Note that the order of the objects on the command-line is as usual  
important.

-sqweek



Ah yes, something I forgot while drifting through the hordes of gcc  
madness that is... not using gcc. Thanks for refreshing my memory. Now  
to see if this is working for kix.




PGP.sig
Description: This is a digitally signed message part


Re: [9fans] troff bibliography

2008-12-09 Thread Pietro Gagliardi

On Dec 9, 2008, at 6:23 AM, [EMAIL PROTECTED] wrote:



Hi,
how do I publish complete bibliographies w/ refer | troff?
(on loonix I use this:
/usr/bin/refer  -B bib |  nroff -mbib
but with refer and tmac.bib from heirloom-doctools: the -B option is  
essential

(beat me for still using loonix))

thanks,
++pac.




You can get V7 refer from /n/sources/contrib/forsyth/refer.tgz.



PGP.sig
Description: This is a digitally signed message part


Re: [9fans] troff bibliography

2008-12-09 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

This is probably because the Heirloom tools are different from the  
Plan 9 tools. I think you should try compiling the Heirloom tools  
using ape/psh and see what happens.


-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkk++AQACgkQuv7AVNQDs+ze/gCeLhTB0Lpap/0nNU7+UHebkm/1
qXYAn0U6MRhB0uEX37UOYoMwrsETbxPo
=+gAv
-END PGP SIGNATURE-



[9fans] troff to postscript with New Century Schoolbook: discrepancies?

2008-12-07 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

New Century Schoolbook is a font included in Plan 9. The troff fonts  
are NR, NI, NB, NX. -ms has a .FP option century.


% cat file
\f(NRHello ― world!
% troff file | page
converting from troff to postscript...
reading through postscript...   ― works
% cat file2
.FP century
Hello ― world!
% troff -ms file2 | page
converting from troff to postscript...
/386/bin/aux/tr2post: stdin:41 :WARNING: cannot find glyph,  
rune=0x2014 stoken=― troff font NR

reading through postscript...   pjw instead of ―

Why?

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkk8EDgACgkQuv7AVNQDs+xuZQCeKR+Ra4y5bvkYM6VdWPjWBilQ
jCkAoIj1z4RtmwZ11pUq5ZKOBi0+KZ2c
=E4fj
-END PGP SIGNATURE-



[9fans] old news?

2008-11-25 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

http://lame.sourceforge.net/download.php

LAME compiles on ... Plan 9, ...


-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkks0XIACgkQuv7AVNQDs+xlAwCfbTb9TmbwMCU6oSETDm3Z+W/l
KVMAn2ZOI+zAajcVfbO/1CsndpgPII3y
=0MQC
-END PGP SIGNATURE-



Re: [9fans] plan9 now officially not the OS with the ugliest GUI anymore

2008-11-19 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

In regard to the GUI itself, it's an interesting concept. THe only  
thing uglier is if it was all text.


-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkkch8ACgkQuv7AVNQDs+zp7ACeJPraZQbqbzPqfnYwOoZk+six
PAwAn1iyDx7DTz1M1k5G03QK09mEUMCO
=F2ir
-END PGP SIGNATURE-



[9fans] web-based plan 9?

2008-11-19 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Take a look at this:

http://www.blazebyte.org/gnextop/

It runs a complete Linux system in a web browser, so users of the  
PlayStation Portable can finally write software for it without fear of  
being bricked by Sony's anti-piracy measures.


Can Plan 9 have this? I don't mean like Inferno grid, I mean like  
drawterm in Java.


-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkkvsgACgkQuv7AVNQDs+z6lQCfdSx87t4dA48MYZwmXipF6NdX
iGgAnjKvlW+udMPyK2UYn89QQ+m8ybPw
=+Ify
-END PGP SIGNATURE-



[9fans] Another observation

2008-11-18 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

The to each his own philosophy of software development (tools, etc.)  
is over.


-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkjTz4ACgkQuv7AVNQDs+xuSgCfe1DiflHgaJIeEZQAeUBIWxID
PXUAn2au5WG7aAHFIpetL1X7AwjU4cnC
=l+CO
-END PGP SIGNATURE-



Re: [9fans] Another observation

2008-11-18 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

I did not get a chance to elaborate when I first wrote this. Here goes:

I'm noticing that consumer appliances (calbe/FIOS boxes), handhelds  
(Blackberries), and even some computers have managed to mush together  
things that may be a convenience but don't belong. I noticed this when  
Verizon announced that their FIOS TV was going to have more widgets.  
Should TV have widgets? Wasn't the channel and pay-per-view enough?


You can argue that the iPhone and competitors are not just phones, but  
what about the other phones that don't compete with them? Why do they  
have stuff like email, game playing (which I do like -- a lot), IM,  
etc.? (I don't write text messages.)


On Nov 18, 2008, at 6:26 PM, Pietro Gagliardi wrote:


-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

The to each his own philosophy of software development (tools,  
etc.) is over.


-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkjTz4ACgkQuv7AVNQDs+xuSgCfe1DiflHgaJIeEZQAeUBIWxID
PXUAn2au5WG7aAHFIpetL1X7AwjU4cnC
=l+CO
-END PGP SIGNATURE-



-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkjUicACgkQuv7AVNQDs+xZCwCgoMdT4fqSfOAvKCJfJSzIcklH
KcgAn0KiCQH0K1XevMTq4Ugx43gsZeAl
=5gWT
-END PGP SIGNATURE-



Re: [9fans] Another observation

2008-11-18 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

all hail erik.

On Nov 18, 2008, at 6:27 PM, erik quanstrom wrote:

The to each his own philosophy of software development (tools,  
etc.)

is over.


i haven't gotten that memo.  about 50% of the software i use
every day is not what anyone else in the world uses.

- erik




-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkjU3UACgkQuv7AVNQDs+ylpQCePncZnnOJw5MPBBhJmtiNqi5P
q2cAn3nRiefolZM/HBeF9W56Ax/KWeee
=QTbq
-END PGP SIGNATURE-



Re: [9fans] How can I use alef?

2008-11-18 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Last time I checked alef,tgz didn't include the x86 port; shame, I  
wanted to try it too.


-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkjkAcACgkQuv7AVNQDs+wtEwCfUaBuz0D6MvAaSUTKNvAw2MCD
O+0An027rvPhi8oy9sN0ZSSDB2Ps/XNA
=o+kX
-END PGP SIGNATURE-



Re: [9fans] Help downloading Plan B using hget

2008-11-14 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Nov 14, 2008, at 4:26 PM, Russ Cox wrote:


hget is different from most other programs of its kind.


depends what you mean by its kind.


command line download tool; I'm comparing it to programs like wget,  
curl, etc.


-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkd7ikACgkQuv7AVNQDs+y/AQCcDICiMviOfxdf5xfNvda87459
hKkAoIcimCB+1t3qGmaZvFDcm4v+1yPJ
=FJrM
-END PGP SIGNATURE-



Re: [9fans] Help downloading Plan B using hget

2008-11-14 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Nov 14, 2008, at 6:21 PM, Dave Eckhardt wrote:


commentary


This is because those programs use stdout for status indication, much  
like hget -v. Think of wget, which is forced to use a terminal in  
order to make a progress bar.


The idea is simple, and I'd like to go into more detail: the modern  
UNIX programmers want to make it easier for a more general public to  
use it, even at the risk of losing what UNIX was originally intended  
to. Ergo, we are more like UNIX than GNU or BSD is.


-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkeCiUACgkQuv7AVNQDs+x4NwCeJwB+z6W4fChQEO9VSB7tz1Xu
vX0An1tEeZlmxBKXEFFG0D+MXstTGL0h
=M4Bq
-END PGP SIGNATURE-



Re: [9fans] Help downloading Plan B using hget

2008-11-14 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1


On Nov 14, 2008, at 6:46 PM, Uriel wrote:


I wonder why was stderr invented...

uriel


Oh yes, that's also something I can explain. Some programmers use the  
definitions literally: stderr is not used for a progress bar, make  
stdprog.


-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkeDv4ACgkQuv7AVNQDs+xlbgCgojH8sYTwAZD6eeDLqadaTcSF
PTkAoK8PCMy7E2THjG34kwNhKjKvvyWl
=EYFS
-END PGP SIGNATURE-



[9fans] Thank you (was Re: Help downloading Plan B using hget)

2008-11-14 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

In a short few hours I have learned to appreciate Plan 9 more.

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkeGZkACgkQuv7AVNQDs+zeiQCfTpAlEmxAVto2p2gshSpwtTnQ
SUgAn2ESZiuP3vSD5nm9RgmId2OzZ65N
=20TR
-END PGP SIGNATURE-



Re: [9fans] nedmail quirk

2008-11-12 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

All the programs that accept ! as a command do this:

% ed file
!echo hello
hello
!

It tells the user that execution has finished.

On Nov 11, 2008, at 11:07 PM, erik quanstrom wrote:


Hash: SHA1

On Nov 11, 2008, at 10:40 PM, erik quanstrom wrote:


does anyone remember why !, | and || echo follow their
output with a !\n?  would anyone miss this behavior?

- erik




Could you give an example?


1: !echo true
true
!
1: 1|wc
  19292070  146786
!




-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkavF4ACgkQuv7AVNQDs+z0kACgkAwZ/J20lZJlJvuDr02BfOWL
/fAAoI7y+G9I2u3FH+3b04/kAYbTiUj/
=BSnh
-END PGP SIGNATURE-



Re: [9fans] nedmail quirk

2008-11-11 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Nov 11, 2008, at 10:40 PM, erik quanstrom wrote:


does anyone remember why !, | and || echo follow their
output with a !\n?  would anyone miss this behavior?

- erik




Could you give an example?
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkaVIoACgkQuv7AVNQDs+wtfACeNERQKfqBC4rT1XuGfylJBaAJ
q+gAn0hWu2JPc7yS0KVOLssnL2q3xCxw
=fH/W
-END PGP SIGNATURE-



Re: [9fans] Next IWP9

2008-11-10 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Nov 10, 2008, at 4:48 PM, Wes Kussmaul wrote:


There are things about Whi$tler that would pose problems for some.


Is it possible to rent a room in the Longhorn? And if there are too  
many people, some of us could go on Blackcomb.


-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkYrc8ACgkQuv7AVNQDs+wq9QCdEdulQX/0KQVHmgQMl3n5/rIH
t1QAn36jCGFecSM62w4+FgK1uCTS8tzR
=Vk6d
-END PGP SIGNATURE-



[9fans] speaking of whistler...

2008-11-10 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Here's a screenshot of Windows 7:

http://en.wikipedia.org/wiki/Image:Windows7Desktop.png

I think this looks familiar.

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkYrlUACgkQuv7AVNQDs+wZfACfQtDTq1ShP1kw1I68WBPFh+pW
fpcAoJuIsDyQgtXCd2CyBP9jcw5mSM/b
=rAVj
-END PGP SIGNATURE-



Re: [9fans] has anyone used xmonad?

2008-11-09 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Nov 9, 2008, at 3:14 PM, Eris Discordia wrote:


What is X good for except eye candy and graphical web browsers ;-?


Masochistic programming and highly-paid tech support teams.

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkXSTEACgkQuv7AVNQDs+zhrQCgq4jkluSJua22U0J+rL8hiouN
j+UAoInw6So94LZJozVIxhn2FcAFSnjf
=RbDW
-END PGP SIGNATURE-



Re: [9fans] Programming tutorial draft

2008-11-07 Thread Pietro Gagliardi

On Nov 7, 2008, at 11:09 AM, Dan Cross wrote:

On Wed, Nov 5, 2008 at 3:03 AM, Bruce Ellis [EMAIL PROTECTED]  
wrote:

I'd like to see a you tube video of the troff.


Dude, don't tempt me.  When (if?) I (ever?) get off of active duty, I
might do a youtube video on troff.  I know that's not quite what you
were saying, but it'd be hilarious.

   - Dan C.

(ps- Bruce, let me know when you'll be stateside again.)



If I made it, it wouldn't be on youtube (I don't want to give up my  
rights to the video). But I would definitely give it to you, the groff  
guys, and the Heirloom guys.


How is this to start:

	This video will teach you troff. What is troff? troff is a document  
preparation system, much like TeX or Microsoft Word. troff is one of  
the first of these systems to support fonts in italic and drawing on  
the page. It was developed by the late Joe Ossanna and is the latest  
and newest in a long line of document programs.
	troff is most like TeX in that the document is a text file containing  
words with formatting commands mixed in. This means you'll have to get  
used to the command line.
	Three primary versions of troff are used today. The official version,  
based of Ossanna's work, is in the Plan 9 from Bell Labs operating  
system. The most common one is groff, a version made for the GNU  
project. There is also Heirloom troff, based off the ones by  
OpenSolaris. All three are free software.
	So as you can see, troff is a Unix tool. But if you are on Windows,  
don't despair: there are ports of these tools to Windows. I will be  
running Plan 9 for my demo.


Let's start by creating a simple document. Create a new text file:

 first_troff

and edit it:

acme first_troff

Now let's type a few words:

hello, world

Save your work. In my case, I middle-click the Put at the top.
Now comes the fun part. In Plan 9, to preview the document, you say

troff first_troff | proof

or

troff first_troff | page

I will use page. With GNU, you convert to a PostScript file and open  
it with an image viewer:


troff first_troff | grops  first_troff.ps

(Heirloom goes here.)



PGP.sig
Description: This is a digitally signed message part


[9fans] libbio questions

2008-11-05 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Hello. Why do we have something like

vlong Boffset(Biobufhdr *r);

instead of

vlong Boffset(Biobuf *r);

and

long Bgetrune(Biobuf *r);

instead of

Rune Bgetrune(Biobuf *r);

Thanks.

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkSacAACgkQuv7AVNQDs+xMIACeNsbjeH+E3dAUcPSc76kzzjuy
Q+oAnArcDCCVkxwVSuy2p4fwYRhVgBLG
=bsZB
-END PGP SIGNATURE-



Re: [9fans] libbio questions

2008-11-05 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Nov 5, 2008, at 11:21 PM, Russ Cox wrote:


At one point, it was possible to declare your own buffered
i/o by just embedding a Biobufhdr and filling it in correctly.


Is that still possible/useful?

Thanks for the rest of the info.

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkScpwACgkQuv7AVNQDs+yOFwCfYKCg+Bv7Dev+gbOwz3bE/8id
ccYAoIGxVrw9M6L6qi23eXdFw3SDQK9Z
=gW3h
-END PGP SIGNATURE-



Re: [9fans] on a slightly more fun note

2008-11-05 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Nov 5, 2008, at 8:53 PM, ron minnich wrote:


Just booted Plan 9 on a 1024+16 node BG/P this week. .


Cool, congrats. Now to see Plan 9 run on HAL :-P

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkScyoACgkQuv7AVNQDs+zvegCfYlCiiFIpCfAYXofsyYexxoNW
TaQAn23qaymUup2NhBmV/RqaEaRs2qlm
=Wu9r
-END PGP SIGNATURE-



Re: [9fans] Questions about plan9.

2008-11-04 Thread Pietro Gagliardi

On Nov 4, 2008, at 8:04 AM, [EMAIL PROTECTED] wrote:


Hi, I just recently fell in love with plan9, it's a great operating
system, However there are somethings I do not know how to do.

1.  How can I get internet through a ethernet cord?(I am not sure
which ethernet card I have , but the computer I have is a Dell
Dimension 1100.)


Try
% ndb/dns -r
% ip/ipconfig
If that doesn't work, use the device manager on another system, such  
as a Linux LiveCD, to find out the chip.



2.  Were can I get a good tutorial on the plan9 C compiler( I have
already read: How to use the plan9 C compiler by Rob PIke.)


I'll put a draft of one I'm making on sources later.



PGP.sig
Description: This is a digitally signed message part


[9fans] Programming tutorial draft

2008-11-04 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

/n/sources/contrib/pietro/programming.pdf

This only covers files, processes, and little else. I began a part on  
segments, but I don't know if it will stay. I haven't touched it since  
August, but I plan to start it again perhaps in a few days.


-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkQ4LIACgkQuv7AVNQDs+zHpACdGRXVREMNC/t1HdCrmqrAyZ/+
QCMAnAwkGvHZ1PnglHKTedSmTjOpFsnS
=9JHE
-END PGP SIGNATURE-



Re: [9fans] Programming tutorial draft

2008-11-04 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Sorry, it also covers Runes.

On Nov 4, 2008, at 6:54 PM, Pietro Gagliardi wrote:


-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

/n/sources/contrib/pietro/programming.pdf

This only covers files, processes, and little else. I began a part  
on segments, but I don't know if it will stay. I haven't touched it  
since August, but I plan to start it again perhaps in a few days.


-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkQ4LIACgkQuv7AVNQDs+zHpACdGRXVREMNC/t1HdCrmqrAyZ/+
QCMAnAwkGvHZ1PnglHKTedSmTjOpFsnS
=9JHE
-END PGP SIGNATURE-



-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkQ4pwACgkQuv7AVNQDs+yK4ACgiSnU6Bq+tYTPHg73yupg0pBx
fTkAn2Iy2NhRbj6udky/g2a6PY4JF/7I
=x2qw
-END PGP SIGNATURE-



Re: [9fans] I want to port some program or driver

2008-11-03 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Nov 3, 2008, at 5:14 AM, Siddharth Prakash Singh wrote:


hi all,

I want to port some program or driver to plan9 which has not been
ported yet and is of high priority.
Please suggest me !

Thanks



the program is...?
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkO3joACgkQuv7AVNQDs+w/ZQCfSEpT6gqTykphxPG2p9h1eIKa
11YAoIOEYEFjj3WtrZ1t5DVqOe5zPJW3
=whTQ
-END PGP SIGNATURE-



Re: [9fans] sources down?

2008-11-02 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Nov 2, 2008, at 1:51 PM, Skip Tavakkolian wrote:

[blank message]


The strangest part? It's been down since this morning (I'm on Murray  
Hill time here on Long Island); longer than usual.

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkN+ccACgkQuv7AVNQDs+w/ngCfVIjCGT18ZDUNV6/uynighKDM
dtgAnjJVMoDnAdfV0YN0wFdzhW4fhYbZ
=gcnp
-END PGP SIGNATURE-



Re: [9fans] sources down?

2008-11-02 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Nov 2, 2008, at 4:58 PM, michael block wrote:


retool them for standard time

isn't that done automatically?
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkkOO7wACgkQuv7AVNQDs+yHxgCgqfsq+xr9i710y0c0Wogr7OIT
JpEAoKIGJAe0FvG0ZX+muMnDimc6KoAe
=sVbs
-END PGP SIGNATURE-



Re: [9fans] troff .XP

2008-10-26 Thread Pietro Gagliardi

On Oct 26, 2008, at 8:39 PM, [EMAIL PROTECTED] wrote:


After a long day writing a paper for my psych class, it came time for
me to make the reference page, using the APA format (see
http://owl.english.purdue.edu/owl/resource/560/06/).  I was looking  
at

an online troff manual, which said that the .XP macro in the MS macro
set should do exactly what I want for the references...  but we don't
seem to have .XP in Plan 9 troff.

Has anyone here written a similar macro for Plan 9?  I'm a bit fried
after a lot of paper-writing and some Matlab work this afternoon or
I'd try to figure something out from the troff manual.

Thanks

John


Really what I want here is .HP from -man but if I use -man I get
really ugly fonts...  yet if I copy over the .de HP chunk from tmac.an
into my .ms file, the formatting doesn't work properly.

John


I modify the .PP macro. Here's one I use for MLA:

.de MP
.in
.RT
.if \\n(1T .sp \\n(PDu
.in +\\(PIu
.ti 0
..



PGP.sig
Description: This is a digitally signed message part


[9fans] How to go about doing screen reading

2008-10-21 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

In pseudocode:

when mouse has not been moved for at least 1 second
find cursor position
if cursor has moved
stop
find window where cursor is
if  cursor has moved or no text window underneath
stop
find line of text in the window device where the cursor is
say the text
when F1 is hit
read out line already typed at open rio window

Any technical problems with this approach?

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkj9sOAACgkQuv7AVNQDs+y/aQCeIuuTrAdNar5BTXXa7oZQNMu7
9XMAn0qmnR5jup2t7cO8GeczROTOYu70
=r7hM
-END PGP SIGNATURE-



Re: [9fans] Are there any blind users of Plan 9?

2008-10-20 Thread Pietro Gagliardi
I'm blind in only one eye and have low vision in the other, so I run  
Plan 9 in a virtual machine with an enlarged screen using Mac OS X's  
Universal Access.


The concept of a Text-to-Speech program for Plan 9 has been floating  
in my head for some time. How can it be made to use some of Plan 9's  
features (/dev/*ctl, /srv, text-based commands, etc.)? I was thinking  
either something like

echo say (voice) (ipa-pronounciation)  /dev/speech
echo sayword (voice) (word)  /dev/speech
then use such a device to build a screen reader.

PS -
On Oct 20, 2008, at 6:15 AM, Jeff R. Allen wrote:

PS: Heh, just found this: http://lsub.org/magic/man2html/1/emacs


That's in the PDF. In fact, it's on the GNU Humor page now, too. I  
wonder how vi is related anymore, though.




PGP.sig
Description: This is a digitally signed message part


Re: [9fans] Newbie looking for pointers

2008-10-15 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Oct 15, 2008, at 8:10 AM, Charles Forsyth wrote:


(i think venti is optional but i might be wrong.)


Yes, it's optional.
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkj2VAwACgkQuv7AVNQDs+xZgACdEsgJT4PaatwcH7wlL6Qm/H62
KyEAnibZ/dBGPvHpGiqusX1HdURPTmUv
=KSZf
-END PGP SIGNATURE-



Re: [9fans] several things

2008-10-13 Thread Pietro Gagliardi

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Oct 13, 2008, at 5:35 PM, Rudolf Sykora wrote:


Hello

few questions:

1) Having a window with rc and pressing CTRL+d usually closes the  
window. However, from time to time it does not. Instead, I can see  
EOT (one character; diagonally) written after the prompt, the window  
stays, I can write anything into the window, but my commands are not  
executed. When does this happen?


When you're running a server, such as ext2srv or dossrv. If I recall  
correctly, this was discussed before.


2) Reading pwd.c I can see 'char pathname[512]' at the beginning of  
the main function. Does it mean plan9 paths are thus limited?


No. How many characters can be stored in an absolute pathname is  
program-dependent.


3) Why do I have to press END key several times to get to the bottom  
of a window (usu when there is a lot of output text from the issued  
command)?

(The rio maunual says just one press.)


rio windows don't scroll by default. To enable scrolling for a certain  
window, middle-click and hit scroll, or type


echo scroll /dev/wctl

To make scrolling the default, edit $home/lib/profile and change every  
instance of


exec rio

to

exec rio -s

Log out and log back in.


4) What is the sense of
bind 'sth' 'the_same_sth'
? (like 'bind / /' or 'bind /usr/ruda/a /usr/ruda/a')


Think of it as making an alias or link.


5) When I do

cd
mkdir a
mntgen a
bind lib a/b
unmount a

all these command finish ok, but I am left with

bind /usr/ruda/lib /usr/ruda/a/b

in the namespace (see the result of the 'ns' command; there you can  
also spot that after issueing the 'mntgen' command a line
'bind /usr/ruda/a /usr/ruda/a/' appears; that relates to my 4th  
question; this bind is the one removed by the 'unmount' command).

How can I get rid of that then?


Delete the namespace by closing the window.

You just found a bug; congratulations.

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkjz0Q8ACgkQuv7AVNQDs+yPUgCePQ1xijeQfxMC8iWZPuzNGCxH
gCMAnR636iteBBjHhYLW4rdKjfIVIkj8
=aCUq
-END PGP SIGNATURE-



Re: [9fans] sorry for the noise; pgp test

2008-10-12 Thread Pietro Gagliardi

How?

On Oct 12, 2008, at 6:00 AM, hiro wrote:


I didn't get your mail, can't read it

On Sun, Oct 12, 2008 at 5:40 AM, Pietro Gagliardi [EMAIL PROTECTED]  
wrote:

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Sorry for the noise; I'm just testing to see if the PGP for Apple's  
Mail
will still let me send the list email. If you cannot read this,  
reply.

Otherwise, disregard.

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.8 (Darwin)

iEYEARECAAYFAkjxcZYACgkQuv7AVNQDs+w78gCgi/fm+POo7k9Uc64u5Oo64ezP
3JsAoI7v9Fz1DKFYori83ph26jPTbR8m
=KbeO
-END PGP SIGNATURE-








Re: [9fans] window -hide rc -c 'label a_name; tail -f some_file'

2008-10-08 Thread Pietro Gagliardi

On Oct 8, 2008, at 2:26 PM, Rudolf Sykora wrote:


Hello,

I'd expect

window -hide  rc -c 'label a_name; tail -f some_file'

would create a new hidden window (and so it does), run the tail  
command (and so it does) and set the name for the hidden window to  
a_name.
The last thing seems to not happen (at least from the viewpoint of  
using the button-3 menu in rio --- I only see an empty field, i. e.  
without any name).

Can anyone tell me what's wrong?

Thanks
Ruda


rc -c only runs the commands given and then terminates. When all the  
processes given to window terminates, the window closes. That's what's  
happening to you. Try this:


window -hide 'label a_name; tail -f some_file; rc'




Re: [9fans] environment + functions

2008-10-08 Thread Pietro Gagliardi

On Oct 8, 2008, at 2:52 PM, Rudolf Sykora wrote:




So, if I continuously want to add and remove functions within one  
shell (running hypothetically forever), do I have to 'manually'  
delete those empty left-behind files? --- that is, not only use

fn name_that_I _don't_need
but also
rm /env/'fn#name_that_I _don't_need' ?

No.

Well... that's an answer, but not very constructive indeed. When do  
those files dissapear?

R.


When the namespace disappears.

You can ignore the file even being there. There is a difference  
between the file and how the program uses them. If the program (rc)  
doesn't have a function given a name but /env does, it makes no  
difference. rc will overwrite the file when you redefine the function.





Re: [9fans] purposeful omission or amnesia

2008-09-12 Thread Pietro Gagliardi

On Sep 12, 2008, at 8:28 AM, Eris Discordia wrote:


completely 'unencumbered' by POSIX.


s/completely/almost /

Pietro




Re: [9fans] Porting Plan 9 to the TI Beagle Board

2008-08-22 Thread Pietro Gagliardi
I'd like to see Plan 9 being run on a portable device, and up until  
now I thought the only ways were to get an iPAQ (but are newer models  
compatible?) or to port 9vx to the iPhone (but does Apple's license  
allow that?). Can we use this board to make an alternative - the new  
bitsy? This seems very feasible, since the board is only 3 inches long  
(and I believe square). How would we get a three-button mouse to be  
emulated?


On Aug 22, 2008, at 10:09 PM, Bruce Ellis wrote:


I've just discussed this with Charles. Vita has a thumb compiler (tc)
which works with 5l.

The Cortex-M3 is thumb-2 only so these two aren't quite sufficient,
but a flag will help.

brucee

On Sat, Aug 23, 2008 at 6:42 AM, Skip Tavakkolian [EMAIL PROTECTED]  
wrote:

this is what brucee said a while back about an ARM Cortex-M3
based device:


I found the data sheet for the
Cortex chip if someone needs it. A bit of a challenge for an arm  
port

but it's fun indeed.


the fun refers to this device:

http://www.stm32circle.com


In the recent NeXT thread Eric mentioned the TI Beagle Board
(http://beagleboard.org/).  It's quite neat:  $150 for a 3 x 3 PCB
w/ a 600 MHz ARM core, HD capable video, and SD card, audio, serial,
USB and DVI ports.  The documentation seems fairly complete,  
although

according the mailing list there are issues about how much of the
video and DSP interfaces will be documented.  Hardware-wise it seems
it only needs Ethernet to make it capable of being a Plan 9  
terminal,

although in theory that can be added via USB.

How much would be involved in porting Plan 9 to it?  Would the  
current

Plan 9 ARM compiler be up to the task?

 John











Re: [9fans] sorry

2008-08-20 Thread Pietro Gagliardi
As will I. This thread has become pointless. I'm done attacking this  
guy. If you need me, I'll be making good programs in Plan 9 or  
watching stuff in iTunes.


On Aug 20, 2008, at 4:16 AM, Steve Simon wrote:


Sorry for feeding the troll, I will shut up.

-Steve






Re: [9fans] Using the Acme Editor

2008-08-19 Thread Pietro Gagliardi

On Aug 19, 2008, at 11:52 AM, Wendell xe wrote:


01. Toggle on/off line wrapping
02. Toggle on/off EOL character display
03. Display line numbers
04. Display ruler
05. Rectangluar block selection
06. Search and replace with confirmation at each item
07. Automatic insertion of spaces for tabs
08. Syntax highlighting of code
09. Code folding
10. Code clips/completion
11. Bookmarks
12. Display file diff with locked parallel windows
13. Customize the contextual display of commands in the tag line
14. Customize the color scheme


Acme is not an IDE. It is a text editor. If you want these facilities,  
implement them yourself. That's what the source is provided for.


Some of your ideas can be implemented as external programs.

3. awk '{ print NR, $0 }' file
7. sed 's/  //g' file  file2  mv file2 file
12. This is harder. I suggest a program that works like so:
% pdiff a.c b.c
#include u.h
#include libc.h

int a;  char a;

void
main(void)  q(void)
{
...
	What I suggest is to see how idiff(1) works. idiff merges two files  
by allowing you to select which difference to use. The source is /sys/ 
src/cmd/idiff.c.





Re: [9fans] Using the Acme Editor

2008-08-19 Thread Pietro Gagliardi

On Aug 19, 2008, at 7:51 PM, Eris Discordia wrote:

Plan 9 obeys the UNIX way: tools that make jobs simpler.


A UNIX better than UNIX? I thought that was just the thing 9people  
claimed to be past. Didn't I hear someone saying, Plan 9 is not  
UNIX? Ahem... GNU's Not UNIX, too, nah?


No, that's not what I said. I said that Plan 9 obeys the UNIX  
philosophy, not that it was UNIX. GNU obeys this philosophy (up to the  
point of where to draw the lines on the size of tools). And to some  
extent, Windows (Windows Movie Maker doesn't call up another computer  
now, does it?)



Everything is a UTF-8 [...]


Do me a favor. Fire up your beloved upas, use mail, and relay one  
email through upas/smtpd to smtp.gmail.com:587 with the words  
שָׁלוֹם עֲלֵיכֶם (Hebrew, Shalom aleichem) or  
سلام علیکم (Arabic, Salam-on alaikom) to my address. Let's  
see if the mail goes through.




Mac, and I use OS X Mail (so I can get my hands on IMAP's folder  
system). How about the fact that Simon was able to give you a  
trademark symbol? Do yourself a favor: YOU test it. Look in /lib/ 
keyboard for some characters and send them here. If they come back as  
sent, you've proven my point. Otherwise, you found a bug.


Everything is a UTF-8 text file or a mountable filesystem, even  
devices
and severs encourages transparency of modules: you can copy a file  
from

a Gopher network in Tokyo to a mobile phone from Mexico or have the
filesystem report how much free space is left without running a  
million

commands or typing a thousand lines of code.


The path from Gopher to your PC--or it was a Mac that you had?--was  
paved years ago on UNIX. Then the path from Tokyo to Mexico was  
built on UNIX, and today it _runs_ on UNIX. Now, the real problem  
begins when you want to get your cell phone to talk 9P-over-IP.


Do you have a 9P client for your cell phone? You wrote it already?  
Does it run on Java? Or Symbian? Or Vendor X's proprietary embedded  
OS? Did you do it on Plan 9? Or did you snatch an SDK written for  
some other livelier OS?


Go fool someone else with your empty rhetoric, buddy.



My rhetoric is not empty. I am not saying go ahead and write that 9P.  
I'm saying the jobs are trivial, only three lines of rc:


gopherfs -m/n/gopher tokyo.ac.jp# Demonstration; don't 
try this
motorola -m/n/cell -M 'RAZR V3' 555 555 
cp /n/gopher/a/b/r.tokyo.jpg /n/cell/pictures/r.tokyo.jpg

Write that in sockets. Since that is what you use, don't you?

As for filesystem usage,

echo fsys all df | con -l /srv/fscons

Go look up the source for GNU df, and tell me if it's that simple.


If you are not like that, leave.


No, I _am_ not like that. I also _don't_ like that. And I've left.  
The post was not for you to chew on, it was for the benefit of the  
thread's originator.




Good riddance. But you're missing a wonderful opportunity. Just open  
your eyes.


On Aug 19, 2008, at 8:10 PM, Eris Discordia wrote:

What exactly do you Get Done (tm) on Plan 9? I mean, aren't there  
easier ways to do it? If yes, staying on Plan 9 is simply fanity-- 
a la vanity-- and fanity is beyond reason; my reason, at least. If  
no, how come your job's so specific that can't be done on much more  
widely used systems? Probably it's just 1-3.


- Programming in userland: mainly compiler design, along with a few  
other projects.

- Document typesetting (I love troff). That's not on your list, is it?
- Goofing off: lots of free games

The point of this all?

Plan 9 is not JUST a research system. It is a complete operating  
system. It has great tools for making greater tools, or for just  
increasing (or decreasing) your productivity. If you're too blunt to  
care, fuck off. You've done that to us already, on many occasions.





Re: [9fans] Using the Acme Editor

2008-08-19 Thread Pietro Gagliardi

Geoff! Why not let Eris read your paper on Why Plan 9 Matters?




Re: [9fans] Using the Acme Editor

2008-08-19 Thread Pietro Gagliardi

Just a few other bits of relevance to the original topic:

On Aug 19, 2008, at 11:52 AM, Wendell xe wrote:

07. Automatic insertion of spaces for tabs


style(6) says not to convert tabs to spaces.


11. Bookmarks
If you know what text the bookmark will point to, make a comment on  
the line above it:

/* C comment */
.\ troff comment
# rc/awk comment
Set the comment to the text of the bookmark. Then, search for the text  
of the bookmark with the appropriate comment delimiters. Easy enough.



16. HTML tag matching
An awk program can do this. The idea is to interpret tags as they come  
in the form of a stack:

codestack
htmlhtml
headhead
html
title   title
head
html
/b  title   error: closing wrong tag
You can also check to see if tags make sense or bad tags are nested.  
For example, don't see bodybody/body/body as normal, nor  
titleb/b/title.





Re: [9fans] Learning how to use sam

2008-08-08 Thread Pietro Gagliardi

On Aug 8, 2008, at 4:44 AM, [EMAIL PROTECTED] wrote:


Besides the paper, manual, and language tutorial, is there anything
else I should read to help me learn how to use sam? Would any
background reading on Plan 9, ed, or anything else be helpful? Thanks.



You're pretty much set with those documents. Note: to typeset the  
tutorial, you will first need to execute


cp /sys/lib/troff/font/devutf/CI /sys/lib/troff/font/devutf/CS
cp /sys/lib/postscript/troff/CI /sys/lib/postscript/troff/CS




[9fans] float.h

2008-08-05 Thread Pietro Gagliardi
Hello. Is there an alternative to the macros in this header? My  
program uses some of them (DBL_MIN, DBL_MAX, DBL_EPSILON), and  
including ape/float.h yields name clashes. Thanks.





Re: [9fans] current state of thread programming

2008-07-28 Thread Pietro Gagliardi

On Jul 28, 2008, at 1:11 PM, andrey mirtchovski wrote:

salad fork. Locks, mutexes, the synchronized keyword; all of these
things can strike fear into the heart of a green developer. Most


That's what you get for using Java.

On Jul 28, 2008, at 1:50 PM, [EMAIL PROTECTED] wrote:

I'm unable to judge what ideas about
parallelism are likely to be useful five or ten years from now, let
alone fifty,


By that time, $50 (not $500 or $5,000, but $50) computers will be  
around that will have processors with as many cores as Blue Gene, thus  
almost completely eliminating the problems of multithreaded  
programming. Data synchronization will be solved by simply turning off  
one of the processors until the critical code has completed.


If only I could tell him that without having to wait for the snail!




Re: [9fans] [plan9mod] C compilers??

2008-07-24 Thread Pietro Gagliardi
bblochi - you failed to solve his problem. Instead you spat out an  
insane commentary on how to compile C programs, and the following both  
show his problem and show he figured out how to do it:


On Jul 23, 2008, at 5:02 AM, [EMAIL PROTECTED] wrote:

did not result in it being found (nor 8c etc).


quertyp9q - I'm sorry, but I don't know why your system came up dry.  
Try running


/usr/glenda/bin/rc/pull

and tell me if the binaries start appearing.

To everyone - I'm writing a C programming tutorial. Perhaps THAT will  
make you happy, bblochi.





Re: [9fans] [plan9mod] C compilers??

2008-07-24 Thread Pietro Gagliardi

On Jul 24, 2008, at 10:23 AM, [EMAIL PROTECTED] wrote:


Thanks! You should forward your friendly comments to Michael A.
Covington. May be he will correct his Newbie`s guide?


I thought those were YOUR words, not his.




Re: [9fans] [plan9mod] C compilers??

2008-07-24 Thread Pietro Gagliardi
All right, let's stop this now. I had just waken up and was a bit  
tired when I wrote that. But I had a reason: you did not answer the  
question of why the system didn't have an 8c.


sorry.




Re: [9fans] A0 poster w/troff

2008-07-23 Thread Pietro Gagliardi

For viewing with page, the simplest way is to add a line of the form

%%BoundingBox: 0 0 w h

where the width and height are in pixels (multiply by 72) before the  
second line of the PostScript output (dpost) and give page the -b  
option.


On Jul 23, 2008, at 8:43 AM, [EMAIL PROTECTED] wrote:


this:

.pl 46.8i
.ll 33.1i
.ps 144
Hello, world!

produces a big font text, but on A4 page,
as viewed in 'page'
bbox is wrong, in foo.ps after running

troff -ms foo | dpost | foo.ps

How can I change the default paper size?
Any hint appreciated,
cheers,

++pac.







Re: [9fans] sam question

2008-07-17 Thread Pietro Gagliardi

On Jul 17, 2008, at 8:28 PM, erik quanstrom wrote:

i suppose you could also type

ctl+m




Re: [9fans] setting up a differnet keyboard

2008-07-16 Thread Pietro Gagliardi

9fat:
cp /sys/lib/kbmap/uk /n/9fat

try again with kbmap=uk and reboot.

On Jul 16, 2008, at 4:46 PM, Robert Hibberdine wrote:


Thanks for reply.

putting kbmap=uk into plan9.ini
gives a message

boot: can't open kbd map: 'uk' file does not exist.

So I triedkbmap=/sys/lib//kbmap/uk in plan9.ini   This didn't  
work either. I got the message


boot: can't open kbd map: 'sys' file does not exist.

Not sure what the next step is, so any help is much appreciated

Bob



Francisco J Ballesteros wrote:

IIRC, putting kbmap=uk
in plan9.ini should work.


On Tue, Jul 15, 2008 at 9:47 PM, Robert Hibberdine
[EMAIL PROTECTED] wrote:


Hi,

I want to setup my new plan9 termnial with a UK keyboard. I found  
kbmap but

this appears to be an interactive program. Even if you do

 kbmap /sys/lib/kbmap/uk

it still acts in an interactive manner. Is this right?

A qick glance at the code reveals that
 cp  /sys/lib/kbmap/uk   /dev/kbmap  (put into my  lib/ 
profile)


should work too,  and it does.   But is this the 'correct' way to  
do it? I
just want my keyboard to be the right one when when my terminal  
windows

start.


TIA

Bob















Re: [9fans] Plan 9 on MacBook?

2008-07-16 Thread Pietro Gagliardi

The ISO I got that was supposed to work natively on an iMac had:
- keyboard error messages (but I think it worked)
- no working mouse
- inverse video
But good luck on a MacBook!

On Jul 16, 2008, at 10:30 PM, [EMAIL PROTECTED] wrote:


I now have a more-or-less unused MacBook. I'm
considering spending some time trying to get Plan 9
working on it. Has anyone gotten beyond confirming
that it won't work out of the box?
Anthony







Re: [9fans] Plan 9 on MacBook?

2008-07-16 Thread Pietro Gagliardi
Intel - there is no prebuilt PPC binary. That ELCR point is what made  
me get QEMU in the first place. You can find the ISO somewhere in /n/ 
sources/contrib. du and you can't miss it; it was made by someone else  
on the list.


On Jul 16, 2008, at 10:40 PM, [EMAIL PROTECTED] wrote:


This was an intel or ppc iMac? Did you make (if so,
how) or acquire (if so, from where) this ISO?

Getting that far would be much better than the
current stock ISO, which gets to the ELCR print.
Anthony







Re: [9fans] notes on the kernel published

2008-07-11 Thread Pietro Gagliardi
1) Did you update them for the 4th edition kernel, or are they still  
3rd edition?

2) Does it include a source code listing?
3) Is it digital or hard print?
4) Is it available in America for USD?

Otherwise, cool!

On Jul 11, 2008, at 3:57 AM, Francisco J Ballesteros wrote:


They are edited by dykinson
(www.dykinson.com)
isbn 978-84-9849-088-6

If I did not a mistake, the pdf in the web is exactly
the same.

Just, FYI.






[9fans] file heuristics on troff input

2008-07-11 Thread Pietro Gagliardi

Just a bit of humor:

COMPUTER
ME
% cd troff
% file *
	advp9prog:directory			yes (old attempt at plan 9 programmer's  
guide)

algoawk:directory   
yes (awk book)
bentley.ms: troff -ms input yes (Bentley 
paper)
bentley2.ms:Ascii text  wtf? 
(Bentley paper retry)
	cod.ms:	troff input		why not -ms? (paper on calculator program  
I'm writing)
	cod.ms.part:Ascii			file doesn't understand .ig and pic? (part of  
cod.ms that doesn't belong yet)
	forloop.ms:Ascii			this is pic input (flowchart on how for loops  
work in JavaScript)

jstut.ms:   HTML file   
very wrong (JavaScript tutorial)
	luxidejavu.ms:			troff input		fine (ripped from p9port, -ms .FP with  
DejaVu and Luxi Sans)
	programming.ms:			c program		no one would dare put a program that big  
into one file, stupid (new attempt at programming tutorial, you'll see  
it when it's done)

school: directory   
good (stuff for school)
% file advp9prog/*
adv9prog/ch1:   Ascii   wtf?
adv9prog/ch2:   c program   not again
	adv9prog/dates:			short Ascii		all right (I date evereything for  
record keeping purposes)

adv9prog/mkfile:short Ascii don't 
you know about mk?
% file algoawk/*
algoawk/book_macros:Ascii   ?
algoawk/ch1:Ascii text  oh my gawd, 
something different!
algoawk/colophon:   Ascii   ...
algoawk/dates:  short Ascii good
algoawk/intro:  Ascii   no
algoawk/mkfile: Ascii   still no mk...
algoawk/show:   rc executable file  right
% file school/*
	...		To save you the trouble, they're either directories or - 
ms input, but either showing directory or Ascii.


A full report of my troff directory and subdirectories is in /n/ 
sources/contrib/pietro/file.funny.


So that's only one file that is absolutely correct. It turns out that  
the problem is file isn't reading the


.FP font

as a troff -ms macro line. In the books, they don't read enough lines  
to see that there are more .PPs than there are #includes. Ah well.


And if you thought that was funny, look at the example of a file that  
actually seeks to more than one line from UNIX in The UNIX-HATERS  
Handbook (now a free PDF from its authors).





Re: [9fans] APE printf difference

2008-07-07 Thread Pietro Gagliardi

C89 does have such a requirement, in two places:

Section 5.1.2.3:
...
- The input and output dynamics of interactive devices shall take  
place as specified in 7.9.3. ... or line-buffered input appear as soon  
as possible, to ensure that prompting messages actually appear prior  
to a program waiting for input.

...

Section 7.9.3:
... Furthermore, characters are intended to be transmitted as a block  
to the host environment when ... input is requested on an unbuffered  
stream, or input is requested on a line buffered stream ...


So there you go. I don't know about C99, but I do know POSIX/SUS are  
designed to be aligned with standard C.


Pietro




Re: [9fans] improvement for vmware

2008-07-06 Thread Pietro Gagliardi

See patch(1) for instructions on contributing a patch.

man -t patch | page

On Jul 6, 2008, at 12:46 PM, Antonin Vecera wrote:


Hello all,

I don't know how to submit a patch, so I try to do it this way...

I have installed Plan 9 in WMware Player and every time when I start
the terminal I have to turn graphics hardware acceleration off .
I can do it in some local config file. But I notice that there is file
/bin/aux/vmware which sets up environment for vmware.
I suggest to place the command echo -n hwaccel off /dev/vgactl  
right here!

...and everybody who will install or run Plan9 in WMware would not see
broken screen.

Antonin






Re: [9fans] replica question

2008-07-06 Thread Pietro Gagliardi

On Jul 6, 2008, at 1:03 PM, Antonin Vecera wrote:


Hello all,

can somebody help me with replica/pull ...

I made some changes to /rc/bin/termrc . After that I decided to move
my changes to /rc/bin/termrc.local and restore termrc . I did:

replica/pull -v -s rc/bin/termrc /dist/replica/network

I expected restoration of termrc to actual distribution version but
nothing happend. Why?

(I solved it with yesterday command but I would like to know why I
was not successful with pull command)


Antonin



Sorry, but I got screwed by that too. -s only works if there is a  
conflict. You'll have to manually copy it from /n/sources/plan9/. Type


9fs sources
cp /n/sources/plan9/rc/bin/termc /rc/bin/termrc




  1   2   >