Sha256: 66e659428599b5b3966afbb0ffe20338fbf4ed4ec65a626bc1e7d2dfcac80fed
Contents?: true
Size: 343 Bytes
Versions: 7
Compression:
Stored size: 343 Bytes
Contents
require 'launchy' module CLIUtils # Pref Action to open a URL in the default # browser. class OpenUrlAction < PrefAction # Runs the action. # @return [void] def run url = @parameters[:url] Launchy.open(url) do |exception| fail "Failed to open URL: #{ exception }" if exception end end end end
Version data entries
7 entries across 7 versions & 1 rubygems