Hello! I’ve got some problems with connecting to GTalk via xmpp4r lib.
I’m trying to run this code:
require ‘rubygems’
require ‘xmpp4r-simple’
include Jabber
jabber = Simple.new(‘[email protected]’, ‘password’)
But ruby returns following error:
client.rb:3:in require': C:/Ruby191/lib/ruby/gems/1.9.1/gems/xmpp4r-simple-0.8. 8/lib/xmpp4r-simple.rb:441: syntax error, unexpected ':', expecting keyword_then or ',' or ';' or '\n' (SyntaxError) when nil: new_presence.show || :online ^ C:/Ruby191/lib/ruby/gems/1.9.1/gems/xmpp4r-simple-0.8.8/lib/xmpp4r-simple.rb:442 : syntax error, unexpected keyword_when, expecting keyword_end when :unavailable: :unavailable ^ C:/Ruby191/lib/ruby/gems/1.9.1/gems/xmpp4r-simple-0.8.8/lib/xmpp4r-simple.rb:443 : syntax error, unexpected keyword_else, expecting keyword_end C:/Ruby191/lib/ruby/gems/1.9.1/gems/xmpp4r-simple-0.8.8/lib/xmpp4r-simple.rb:490 : syntax error, unexpected keyword_end, expecting $end from client.rb:3:in
’
Really sorry for my bad English I don’t know what’s the matter. I was
looking for similar problems here, on forum and I ‘googled’ it but I
didn’t receive any good results. Hope I’m understandable.