diff options
| author | Alexander Færøy | 2014-05-31 13:10:46 +0200 | 
|---|---|---|
| committer | Alexander Færøy | 2014-05-31 13:10:46 +0200 | 
| commit | 2d0759e6ca5767b48bcc85bf38c2c43d5f0b63b1 (patch) | |
| tree | 1c5e6d817c88e67b46e216a50e0aef5428bf63df /scripts/ignorsula.pl | |
| parent | 2d080422d79d1fd49d6c5528593ccaaff9bfc583 (diff) | |
| download | scripts.irssi.org-2d0759e6ca5767b48bcc85bf38c2c43d5f0b63b1.tar.bz2 | |
Import scripts from scripts.irssi.org
Diffstat (limited to 'scripts/ignorsula.pl')
| -rw-r--r-- | scripts/ignorsula.pl | 29 | 
1 files changed, 29 insertions, 0 deletions
| diff --git a/scripts/ignorsula.pl b/scripts/ignorsula.pl new file mode 100644 index 0000000..0dfe938 --- /dev/null +++ b/scripts/ignorsula.pl @@ -0,0 +1,29 @@ +#!/usr/bin/perl + +use strict; +use Irssi; + +use vars qw($VERSION %IRSSI); + +$VERSION = "1.999999999543675475473856-FDIV-final"; +%IRSSI = ( +	authors		=> 'apic', +	contact		=> 'apic@IRCnet', +	name		=> 'ignorsula', +	description	=> 'script to show ignored message in censored form', +	license		=> 'public domina', #no typo +	url		=> 'http://irssi.apic.name/ignorsula.pl', +); + +Irssi::theme_register(['stopp', "\02\03" . "0,4STOPP\03\02 {msgnick \$0}"]); + +sub handle_msg { +	my ($srv, $msg, $nick, $addr, $dst) = @_; +	if($srv->ignore_check($nick, $addr, $dst, $msg, MSGLEVEL_PUBLIC)) { +	        $srv->printformat($dst, MSGLEVEL_PUBLIC, "stopp", $nick); +        } +} + +Irssi::signal_add_first("message public", "handle_msg"); +Irssi::signal_add_first("message private", "handle_msg"); +Irssi::signal_add_first("ctcp action", "handle_msg"); | 
