File: libnotify.rb

package info (click to toggle)
mikutter 3.5.0%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 10,256 kB
  • ctags: 2,165
  • sloc: ruby: 19,079; sh: 205; makefile: 20
file content (8 lines) | stat: -rw-r--r-- 444 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
# -*- coding: utf-8 -*-
# notify-sendコマンド又はruby-libnotifyで通知を表示する。

if require_if_exist('RNotify') and defined?(Notify) and Notify.init("mikutter") # ruby-libnotifyがつかえる場合
  require File.expand_path File.join(File.dirname(__FILE__), 'rnotify')
elsif command_exist? 'notify-send' # notify-sendコマンドが有る場合
  require File.expand_path File.join(File.dirname(__FILE__), 'notify-send')
end