Class: WhatIsItAbout::Github
- Inherits:
-
Object
- Object
- WhatIsItAbout::Github
- Defined in:
- lib/what_is_it_about/github.rb
Instance Attribute Summary collapse
-
#client ⇒ Object
readonly
Returns the value of attribute client.
Instance Method Summary collapse
-
#initialize ⇒ Github
constructor
A new instance of Github.
Constructor Details
#initialize ⇒ Github
Returns a new instance of Github.
11 12 13 14 15 16 17 18 19 20 21 22 23 |
# File 'lib/what_is_it_about/github.rb', line 11 def initialize token = WhatIsItAbout.config['github']['token'] if WhatIsItAbout.config['github'] unless token $stderr.puts <<-MESSAGE Set GITHUB TOKEN https://github.com/settings/tokens in ~/.what_is_it_about github: token: <YOU GITHUB TOKEN> MESSAGE exit(1) end @client = Octokit::Client.new(access_token: token) end |
Instance Attribute Details
#client ⇒ Object (readonly)
Returns the value of attribute client.
9 10 11 |
# File 'lib/what_is_it_about/github.rb', line 9 def client @client end |