git: 9front

Download patch

ref: 048b389d041294b163c87d2c4b0c2d5c505bda05
parent: 07dedc5cf4936895b5899e765477e13a8ab5324b
author: cinap_lenrek <cinap_lenrek@gmx.de>
date: Thu Oct 11 21:05:34 EDT 2012

ircrc: various improvements (thanks again pap!)

the -t option was ineffective. this fixes is.

fix incompatibility with 9vx as its tcp/status
file returns slightly different format than
Plan 9.

strip annoying  character from nickserv.

--- a/rc/bin/ircrc
+++ b/rc/bin/ircrc
@@ -34,6 +34,10 @@
 	echo NICK $nick > $netdir/data
 	if (~ $#pass 1)
 		echo PRIVMSG 'nickserv :'identify $"pass > $netdir/data
+	if(~ $#target 1){
+		title
+		echo JOIN $target > $netdir/data
+	}
 	while (cmd=`{read}) {
 	msg=()
 	out=()
@@ -148,7 +152,7 @@
 }
 
 fn pretty {
-	while (~ `{cat $netdir/status} Established*) {
+	while (~ `{cat $netdir/status} *Established*) {
 		line=`{read}
 		switch ($line) {
 		case *JOIN* *QUIT* *PART* *NICK*
@@ -231,6 +235,6 @@
 	netdir=`{basename -d $clonefile} ^ / ^  `{cat /fd/4}
 	echo connect $ip!$port >$netdir/ctl || exit 'cannot connect'
 	echo connected to tcp!$ip!$port on $netdir
-	cat $netdir/data | tr -d '
' | pretty & 
+	cat $netdir/data | tr -d '
' | pretty & 
 	work
 }
--