class Vpr::CLI

Attributes

url[R]

Public Class Methods

new(args = [], local_options = {}, config = {}) click to toggle source
Calls superclass method
# File lib/vpr/cli.rb, line 9
def initialize(args = [], local_options = {}, config = {})
  super
  select_remote
  @url = Url.new
end

Public Instance Methods

branch() click to toggle source
# File lib/vpr/cli.rb, line 39
def branch
  Launchy.open(url.branch_url)
end
branches() click to toggle source
# File lib/vpr/cli.rb, line 34
def branches
  Launchy.open(url.branches_url)
end
home() click to toggle source
# File lib/vpr/cli.rb, line 19
def home
  Launchy.open(url.home_url)
end
issues() click to toggle source
# File lib/vpr/cli.rb, line 29
def issues
  Launchy.open(url.issues_url)
end
pull(branch = nil) click to toggle source
# File lib/vpr/cli.rb, line 50
def pull(branch = nil)
  Launchy.open(url.pull_url(branch))
end
pulls() click to toggle source
# File lib/vpr/cli.rb, line 24
def pulls
  Launchy.open(url.pulls_url)
end
version() click to toggle source
# File lib/vpr/cli.rb, line 65
def version
  puts Vpr::VERSION
end
visit(commit) click to toggle source
# File lib/vpr/cli.rb, line 55
def visit(commit)
  Launchy.open(url.commit_url(commit))
end

Private Instance Methods

select_remote() click to toggle source
# File lib/vpr/cli.rb, line 71
def select_remote
  Configuration.remote = options[:remote].to_sym
end