bind test - !test pub:test proc pub:test {nick uhost handle chan arg} { if {[string equal -nocase "$chan" "#channelname"]} { set binary {/tmp/list.sh} set section [lindex $arg 0] foreach line [split [exec $binary $section] "\n"] { putquick "PRIVMSG $chan :$line" } } else { } }