1
0
Fork 0
mirror of https://github.com/fluffle/goirc synced 2025-09-05 16:33:19 +00:00

Fix up README and example client.

This commit is contained in:
Alex Bramley 2013-02-16 11:04:06 +00:00
parent f27e56c8b0
commit a88b866b63
2 changed files with 6 additions and 6 deletions

View file

@ -18,17 +18,17 @@ Synopsis:
func main() {
flag.Parse() // parses the logging flags.
c := irc.SimpleClient("nick")
c := irc.Client("nick")
// Optionally, enable SSL
c.SSL = true
// Add handlers to do things here!
// e.g. join a channel on connect.
c.AddHandler("connected",
c.HandleFunc("connected",
func(conn *irc.Conn, line *irc.Line) { conn.Join("#channel") })
// And a signal on disconnect
quit := make(chan bool)
c.AddHandler("disconnected",
c.HandleFunc("disconnected",
func(conn *irc.Conn, line *irc.Line) { quit <- true })
// Tell client to connect