class Gemsmith::Gem::Inspector

Provides the ability to investigate a gem in greater detail.

Attributes

shell[R]

Public Class Methods

editor() click to toggle source
# File lib/gemsmith/gem/inspector.rb, line 9
def self.editor
  ENV.fetch "EDITOR"
end
new(shell: Open3) click to toggle source
# File lib/gemsmith/gem/inspector.rb, line 13
def initialize shell: Open3
  @shell = shell
end

Public Instance Methods

edit(specification) click to toggle source
# File lib/gemsmith/gem/inspector.rb, line 17
def edit specification
  shell.capture3 self.class.editor, specification.path
end
visit(specification) click to toggle source
# File lib/gemsmith/gem/inspector.rb, line 21
def visit specification
  shell.capture3 "open", specification.homepage_url
end