Sha256: 2dd8211e686d9b2c00a05543c326646c59ba06ada048c78b1a741f620f89e131

Contents?: true

Size: 514 Bytes

Versions: 6

Compression:

Stored size: 514 Bytes

Contents

require "terminal-notifier"

module Linner
  class Notifier
    class << self
      def profile
        time = Time.now
        yield
        puts "šŸœ : Done in #{'%.3f' % (Time.now - time)}s."
      end

      def error(message)
        puts message = "šŸ‘» : #{message}!"
        if Linner.env.notification && TerminalNotifier.available?
          TerminalNotifier.notify message, :title => 'Linner'
        end
      end

      def exit
        puts "\ršŸµ : Let's take a break!"
      end
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
linner-0.4.5 lib/linner/notifier.rb
linner-0.4.4 lib/linner/notifier.rb
linner-0.4.3 lib/linner/notifier.rb
linner-0.4.2 lib/linner/notifier.rb
linner-0.4.1 lib/linner/notifier.rb
linner-0.4.0 lib/linner/notifier.rb