class GithubFlowCli::CLI
Public Instance Methods
login()
click to toggle source
# File lib/github_flow_cli/cli.rb, line 11 def login Config.username = ask("Github username:") password = ask("password:", echo: false) Config.oauth_token = authorize(Config.username, password) puts "\nsuccessfully login!" rescue Octokit::Unauthorized puts "\nauthentication failed, please try again." retry end
repo()
click to toggle source
# File lib/github_flow_cli/cli.rb, line 27 def repo puts(Local.repo&.slug || "remote repo not found!") end
user()
click to toggle source
# File lib/github_flow_cli/cli.rb, line 22 def user puts API.user[:login] end