dominikh1 changed the topic of #cinch to: The IRC Framework | Latest version: Cinch 2.0.6
Spami has joined #cinch
Spami has quit [Quit: This computer has gone to sleep]
Guest23791 has quit [Ping timeout: 264 seconds]
petru has joined #cinch
petru is now known as Guest50997
rikai has quit [Read error: Connection reset by peer]
rikai has joined #cinch
v0n has joined #cinch
v0n has quit [Ping timeout: 276 seconds]
max96at has quit [Quit: Textual IRC Client: www.textualapp.com]
postmodern has quit [Quit: Leaving]
postmodern has joined #cinch
HelloBot has joined #cinch
<HelloBot> hi
<HelloBot> hello
<HelloBot> Heloo
<HelloBot> hello
<dominikh> If you're looking for your bot, it's in a different channel...
<HelloBot> testing
cinchian has joined #cinch
<HelloBot> hello
<dominikh> ... and I didn't intend you to bring your bot here; test it in the right channel. The examples go there for a reason :) And if it's the plugin examples, it'll be !hello.
cinchian has quit [Ping timeout: 240 seconds]
HelloBot has left #cinch [#cinch]
<UberDragon> what is the event for kick and ban?
<UberDragon> n'm looks like I have :kick working.. :ban not so much
<leftylink> is there actuallyi a :ban event? I would have just expected it to be part of the :mode event
<leftylink> oh, there is, interesting
<UberDragon> hmm now trying to figure out how to get out who was kicked instead of who was doing the kicking lol
<leftylink> the :ban event seems to work OK for me, on freenode at least. I don't think a different network would mess it up, but you never know
<leftylink> as for the who got kicked
<leftylink> the only way I saw how to do that
<leftylink> m.params[1]
<UberDragon> k I'll try it
<leftylink> incidentally, m.params[0] is the channel (but that's also m.target), and m.params[2] is kick message (but I think that should be m.message as well)
<UberDragon> I see.. thanks.. m.target is probably what I'm looking for :P
v0n has joined #cinch
<leftylink> ah, that's what I hoped at first too
<leftylink> but I think you'll see that it is not to be
rikai_ has joined #cinch
rikai_ has quit [Read error: Connection reset by peer]
v0n has quit [Ping timeout: 246 seconds]
rikai has quit [Ping timeout: 246 seconds]
rikai has joined #cinch
rikai has quit [Read error: Connection reset by peer]
<UberDragon> :) yeah m.target turns out to be the channel
<rob_> so, is it normal to make a plugin that listens to more than one event?
<UberDragon> I don't know
<UberDragon> hehe
<rob_> like, i'd like an auto-op plugin that ops people when they join and ops people when the bot gets opped, for example
* UberDragon is writing a !seen plugin.. it needs to track all the ways it can see a nick :)
<rob_> so i would assume i'd do: listen_to :join, :op
<UberDragon> you can definitely put them on separate lines
<UberDragon> I don't know if you can chain them like that
<UberDragon> listen_to :join, method: :join_method
<rob_> ahhh
<UberDragon> listen_to :op, method: :op_method
<rob_> by default it just uses the 'listen' method, right? but i can customize the method name?
<UberDragon> etc
<rob_> awesome, thank you!
<UberDragon> np :)
<rob_> the cinchrb website seems to be down
<rob_> and i realize there are docs for the bot, but are there any more indepth examples than the basic and plugins?
<UberDragon> not that I know of
<UberDragon> but then I'm pretty new with cinch
<UberDragon> git hub is down? o.O
<rob_> UberDragon: looks ok here?
<rob_> UberDragon: any idea how you write to the log?
<UberDragon> puts
<rob_> i've just been using 'puts' but obviously thats not optimal
<UberDragon> thats what I've been using
<UberDragon> I don't know of a better way (yet)
<rob_> there must be a log object
<Cinchy> [URL] File: Logging — Documentation for cinchrb/cinch (master)
<UberDragon> woot there ya go
rickmasta has joined #cinch
<rob_> any idea if its possible to tell if a user has identified with nickserv?
<UberDragon> check the mode on yourself
<UberDragon> +r is registered..
<UberDragon> just a guess though
<leftylink> hmm, far as I can tell you can't check the mode of other users
<leftylink> you can check the user's authname
<leftylink> the various networks might handle it differently though, I don't know
<UberDragon> you can check the mode of yourself though (bot could check it's own modes to see if +r is there?)
<UberDragon> hmm no +r on freenode
<UberDragon> n/m ; ;
rickmasta has quit [Quit: Leaving...]
<dominikh> User#authname will be nil if the user hasn't identified.
<UberDragon> good to know
<rob_> dominikh: thanks!
<rob_> dominikh: so would this be ok: if ops.include?(msg.user.nick) and ! User(msg.user.authname).nil?
<rob_> User(msg.user).authname.nil?
<rob_> rather
<dominikh> well it's valid ruby. no idea what the logic behind that is. and you don't need to put User() around a User object. msg.user.authname
<rob_> ah ok, thanks
kludge` has quit [Ping timeout: 264 seconds]
kludge` has joined #cinch
<rob_> dominikh: hmm, .authenticated method always returns 'nil' even when my user is authenticated (rob__)
<leftylink> is it really .authenticated, rather than .authed?
<rob_> authname, rather
<leftylink> hmm
<dominikh> rob_: which version of Cinch?
<rob_> dominikh: i cloned from github yesterday
<dominikh> also, if you check a user's authname while he's not authed and he auths in the meantime, while not sharing any channel with the bot, it will cache the "not authed" status until you do an explicit refresh
<dominikh> !eval User("rob__").authname
<Cinchy> "rob_"
<dominikh> UberDragon: by the way, you don't need to open a new PR, you could've just squashed the commits and git push --force'd the branch
<dominikh> for the future
<UberDragon> sorry I couldn't figure out how to do it :/
<UberDragon> ah --forece
<dominikh> git rebase -i to squash the commits, git push --force to overwrite the feature branch
<UberDragon> *--force
<UberDragon> k
<rob_> dominikh: how can i do a refresh?
<UberDragon> thanks
<dominikh> rob_: User#refresh
<rob_> dominikh: excellent, thanks
<rob_> hmm, msg.user.authname.inspect always returns nil
<rob_> oh wait
<rob_> oh ok cool
UberDragon has quit [Remote host closed the connection]
<rob_> is it possible for a bot to connect to multiple servers?
<dominikh> a single bot? no.
<dominikh> you can run multiple bot instances in a single interpreter, but the bots themselves won't share state
<rob_> ah ok, how do you run multiple bots?
<rob_> s/bots/instances/
<dominikh> same way you run a single bot, just multiple of them; stuffing the calls to Bot#start into threads of their own
<rob_> ah, i did try that
<rob_> for some reason it didnt work, will have to try again
<dominikh> good luck. I'll be going to bed now.
<rob_> laters, thanks for the help :)
max96at has joined #cinch
max96at has left #cinch [#cinch]
rickmasta has joined #cinch
rickmasta has quit [Quit: Leaving...]
postmodern has quit [Quit: Leaving]
v0n has joined #cinch
UberDragon has joined #cinch
UberDragon has quit [Remote host closed the connection]
UberDragon has joined #cinch
<UberDragon> how would I force the bot to reconnect to server upon trigger?
rikai has joined #cinch
<UberDragon> I tried bot.quit; sleep(30); bot.start but it never starts back up :/
<UberDragon> mm perhaps I need to do it on :disconnect
<UberDragon> what is the proper way for me to log to status (besides puts)
<UberDragon> Logger.info("message here?")
<UberDragon> seems to hang connection soon as I try to add that to a plugin
<UberDragon> nm I got it to work log("message",type)
Guest50997 has joined #cinch
Guest50997 has quit [Changing host]
Guest50997 is now known as petru
v0n has quit [Read error: Connection reset by peer]
Spami has joined #cinch