We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 6165274 + ad8c031 commit 2f828edCopy full SHA for 2f828ed
Ruby/lib/terminal-notifier.rb
@@ -6,7 +6,7 @@ module TerminalNotifier
6
class UnsupportedPlatformError < StandardError; end
7
# Returns wether or not the current platform is Mac OS X 10.8, or higher.
8
def self.available?
9
- @available ||= Gem::Version.new(version) > Gem::Version.new('10.8')
+ @available ||= (/darwin/ =~ RUBY_PLATFORM) && Gem::Version.new(version) > Gem::Version.new('10.8')
10
end
11
12
def self.version
@@ -25,7 +25,7 @@ def self.execute(verbose, options)
25
26
result
27
else
28
- raise UnsupportedPlatformError, "terminal-notifier is only supported on Mac OS X 10.8, or higher."
+ STDERR.print "terminal-notifier is only supported on Mac OS X 10.8, or higher."
29
30
31
0 commit comments