xchat script: notify-osd nick notification system

here's a simple nick notification system for xchat using ubuntu notification system. it will execute notify-osd comment when someone mention your nick in public channel or private message. it's good for those who like to minimize their xchat while doing something :)
on PRIVMSG mynick {
if { [string match -nocase "*[me]*" $_rest] } {
	set thatcontext [getcontext]
	set thiscontext [findcontext]
	if { ![string equal $thiscontext $thatcontext]} {
		splitsrc
		if { ![regexp {listOf|nickYou|wantTo|execludeHere} $_nick] } {
			exec notify-send -i xchat -t 3000 "$_nick/[channel $thatcontext]" "$_rest"
			complete EAT_XCHAT
		   }
	 }
}
complete
}
Tagged with: , , ,
Posted in programming

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>