I need to encrypt keystore file. I've installed travis using gem. I can't able to login travis using my github account. Already travis is linked with github account.
Ruby: Ruby 2.0.0-p645
RubyGem : 2.4.8
CLI : 1.8.8
**Error:**
Last Exception
An error occurred running `travis login --pro`:
TypeError: no implicit conversion of nil into String
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/json/common.rb:155:in `initialize'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/json/common.rb:155:in `new'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/json/common.rb:155:in `parse'
from /Library/Ruby/Gems/2.0.0/gems/travis-1.8.8/lib/travis/tools/github.rb:262:in `gh_error'
from /Library/Ruby/Gems/2.0.0/gems/travis-1.8.8/lib/travis/tools/github.rb:211:in `rescue in basic_auth'
from /Library/Ruby/Gems/2.0.0/gems/travis-1.8.8/lib/travis/tools/github.rb:208:in `basic_auth'
from /Library/Ruby/Gems/2.0.0/gems/travis-1.8.8/lib/travis/tools/github.rb:215:in `login'
from /Library/Ruby/Gems/2.0.0/gems/travis-1.8.8/lib/travis/tools/github.rb:80:in `possible_tokens'
from /Library/Ruby/Gems/2.0.0/gems/travis-1.8.8/lib/travis/tools/github.rb:49:in `each_token'
from /Library/Ruby/Gems/2.0.0/gems/travis-1.8.8/lib/travis/tools/github.rb:36:in `with_token'
from /Library/Ruby/Gems/2.0.0/gems/travis-1.8.8/lib/travis/cli/login.rb:31:in `login'
from /Library/Ruby/Gems/2.0.0/gems/travis-1.8.8/lib/travis/cli/login.rb:40:in `run'
from /Library/Ruby/Gems/2.0.0/gems/travis-1.8.8/lib/travis/cli/command.rb:198:in `execute'
from /Library/Ruby/Gems/2.0.0/gems/travis-1.8.8/lib/travis/cli.rb:64:in `run'
from /Library/Ruby/Gems/2.0.0/gems/travis-1.8.8/bin/travis:18:in `<top (required)>'
from /usr/local/bin/travis:23:in `load'
from /usr/local/bin/travis:23:in `<main>'
Can anyone help me to solve this issue.
Thanks
The issue was Ruby which wasn’t up-to-date. I've updated it and its working fine.
Below are the commands to follow:
\curl -sSL https://get.rvm.io | bash -s stable --ruby
To install latest stable version use the command below:
rvm install ruby-2.4.2
Install travis:
sudo gem install travis -v 1.8.8 --no-rdoc --no-ri
Now I’m able to login into Travis using my GitHub account.