bind pub - !add regex_rlstest set bot(chans) "#chan1 #chan2 #chan3" foreach one $bot(chans) { set bot(dupe-[string tolower $one]) "" } proc regex_rlstest {nick host handle chan arg} { global bot putlog "$arg" if { [string match $arg $bot(dupe-[string tolower $chan])] } { putlog "\002DEBUG:\002 Skipping ($bot(dupe-[string tolower $chan])) from ($chan), already seen it." return } set stripped_rls [string map -nocase {"repack." ""} $arg] set bot(dupe-[string tolower $chan]) $arg if { [regexp -nocase -inline -- {\.repack\.} $arg] } { putquick "PRIVMSG $chan :REPACK RELEASE -> !nuke $stripped_rls get.repack" } else { putquick "PRIVMSG $chan :$stripped_rls is not a REPACK RELEASE." } }