irc: Update irc code to use actors.
authorChristopher Allan Webber <cwebber@dustycloud.org>
Fri, 23 Dec 2016 14:50:06 +0000 (08:50 -0600)
committerChristopher Allan Webber <cwebber@dustycloud.org>
Fri, 23 Dec 2016 14:50:06 +0000 (08:50 -0600)
commit3e27bb39df3dbaf65bd0581131610bfe6c824720
tree61005c08a32038b628efaf459da31a16e28000a6
parentd0a86ba4c62607a2051729a81844adabb2760b25
irc: Update irc code to use actors.

Also some significant cleanup.  But more can still be done!

* 8sync/systems/irc.scm: Adjust exports.
(irc-line, irc-format, irc-display, irc-send-message)
(irc-send-formatted, handle-login, <irc-line>)
(default-handle-privmsg, make-handle-line, irc-loop)
(default-line-handler, queue-and-start-irc-agenda!): Removed.
(parse-line): Return multiple values rather than the <irc-line>
record.
(irc-line-username): Update to use prefix rather than pulling
out of <irc-line>.
(condense-privmsg-line): Update docstring to call `is-action' `emote?'.
(echo-message): Renamed from echo-back-message.  Change argument list
and body to match new version and add docstring.
(<irc-bot>, irc-bot-username, irc-bot-server, irc-bot-channels)
(default-irc-port, irc-bot-line-handler, irc-bot-socket)
(irc-bot-realname, irc-bot-init, irc-bot-main-loop, irc-bot-dispatch-line)
(irc-bot-send-line): New variables.

* demos/ircbot.scm (handle-line): Renamed from `handle-message'.
Adjust body for actors edition.
(display-help, parse-args, run-bot): New variables.
(main): Adjusted for new structure.
8sync/systems/irc.scm
demos/ircbot.scm