proxy_backlog.pl

Version: 0.0.0
Download
View source
signature

This script sends the backlog of channels in an irssi with irssi-proxy to a client requesting it.
WARNING: This script is still experimental, it's not finished yet.
Usage: run the script on the client with irssi-proxy, connect to it, and do /ctcp -proxy- IRSSIPROXY BACKLOG SEND, or add that to the -autosendcmd to get the backlog on connect
It's not release quality yet at all, pretty alpha, but I already use it, so there might be some other people insane enough too to use it. I'll probably add features and fix some of the bugs later, but until irssiproxy is made really scriptable, this will stay a very hacky script, and some bugs just can't be fixed.

Bugs:

  • Colors only work correctly with Irssi as the client. To enable them replace "get_text(0)" with "get_text(1)" in the script
  • Timestamp of the client is printed before the line received, resulting in 2 timestamps
  • The ctcp -proxy- gets sent to the server too, resulting in a -!- -proxy-: No such nick/channel message that should be ignored
  • When multiple client are connected to the same proxy, they all receive the backlog
  • Because the script fakes notices sent to the channel, some script might behave strangely (but almost every bouncer has this problem too)
  • Only backlog from channels where you're still in will be sent
  • When sending backlog from a channel, it sends everything in the window of that channel. So it doesn't work correctly with multiple channels in one window
  • And much more probably...

Useful tips you could give me:

  • How should the messages sent to the client be formated, to be displayed correctly in most clients? (converting to ansi or mirc-colors isn't the real problem)
  • How to see which lines belong to which channel with multiple items in same window
  • How should it handle channels you aren't in, or windows without channels...
  • How should the client tell the proxy to send backlog (now with /ctcp -proxy ...)
  • A patch to make irssiproxy perlscriptable ;)