cl-irc is a Common Lisp IRC client library that features (partial) DCC, CTCP and all relevant commands from the IRC RFCs (RFC2810, RFC2811 and RFC2812). It uses ASDF and has been tested mostly on SBCL but should work for other implementations with little or no extra code.
The code is released under an MIT-style license. I need to mention that Jochen Schmidt laid the groundwork for this library with his Weird-IRC IRC client and that therefore some of the code is copyright him.
If you have asdf-install, just:
$ asdf-install cl-irc
cl-irc can manually be downloaded from here: cl-irc_latest.tar.gz .
Questions, feature requests, and bug-reports are welcome on email@example.com.
* (require :cl-irc) * (in-package :irc) * (defvar connection (connect :nickname "mynick" :server "irc.somewhere.org")) * (read-message-loop connection) ;; That's it. Interrupt the read-message-loop and do: * (join connection "#lisp") ;; etc. (look at command.lisp) to operate the library. After issuing ;; a command, you need to get back on the feed: * (read-message-loop connection) ;; If you need to do something on every join, do: * (defun my-hook (message) <do-something>) * (add-hook connection 'irc-join-message #'my-hook) ;; and it will be run next time the library receives an ;; irc-join-message. For a full list of messages you can hook into, ;; look at event.lisp. ;; Your connection object will get updated by the library with regards ;; to users joining/parting channels, you joining/parting channels, ;; etc. Look at protocol.lisp's connection object for slots and ;; methods.