Skip to content

'gh browse' checks for launchy & fails if launchy installed, but not through gems #31

@huitseeker

Description

@huitseeker

The 'browse' command determines if I have launchy installed in the following fashion:

helper :has_launchy? do |blk|
  begin
    gem 'launchy'
    require 'launchy'
    blk.call
  rescue Gem::LoadError
    STDERR.puts "Sorry, you need to install launchy: `gem install launchy`"
  end  
end

Except that in some cases, I may have installed launchy through other means, such as using a package (e.g. the Debian/Ubuntu policy favors packages over gems, so this will apply when launchy is eventually packaged, or even right now using the most excellent thwarted/gem2deb ). In those cases, commenting
gem 'launchy'
above suffices to get 'gh browse' running.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions