class Stax::Github
Public Class Methods
exists?()
click to toggle source
check if this sha exists in github
# File lib/stax/github.rb, line 17 def self.exists? !octokit.commit(Git.repo, Git.sha).nil? rescue Octokit::NotFound false end
octokit()
click to toggle source
# File lib/stax/github.rb, line 7 def self.octokit abort('Please set GITHUB_TOKEN') unless ENV['GITHUB_TOKEN'] @_octokit ||= Octokit::Client.new(access_token: ENV['GITHUB_TOKEN']) end