all repos — dotfiles @ 5418f7aef0eee82c89c0b7d99a4f38837548b907

my *nix dotfiles

weechat/gt.py (view raw)

 1import weechat, re
 2# modifies the string about to be sent to the IRC server
 3# thus, not interfering with non-IRC buffer text like wee-slack
 4
 5weechat.register(
 6    "gt.py", "icyphox", "1.0", "MIT", "greentexting like the hacker called 4chan", "", ""
 7)
 8
 9def greentext_cb(data, modifier, modifier_data, string):
10    return re.sub(r">(?! )", "\x033>", string)
11
12weechat.hook_modifier("irc_out1_privmsg", "greentext_cb", "")