Skip to content

threadhead/growl-ssh-notifier

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

32 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

GrowlSSHNotifier for Ruby

This library provides the ability to send growl notifications to local or remote computers using ssh.

This release provides the following features:

  • Simple API.

  • Smartly selects ssh method to minimize time.

  • Allows the use of custom icons or images.

Download

The latest version of GrowlSSHNotifier can be found at

Requirements

  • net-ssh (version >= 2.0), if sending notifications to remote hosts that do not have rsa/dsa authentication

Installation

Download the sources directly and copy the growl-ssh-notifier directory into the lib directory (or directory of your choice) of your project. Add the following to your code:

require 'lib/growl_ssh_notifier'

You can also clone the repository into your lib directory

git clone git://github.com/threadhead/growl-ssh-notifier.git lib/growl-ssh-notifier

Then add the following to your code:

require 'lib/growl_ssh_notifier'

Testing

You can execute the basic library test with a simple rake test from the growl-ssh-notifier directory.

There are optional tests that will send growl notifications to either the localhost computer or remote computers.

Localhost Notifications

Send test notifications to the localhost machine.

rake test:local_notification

Remote Notifications

You must duplicate the test/remote_notifications/remote_hosts_example.yml file to remote_hosts.yml and edit the YAML file to enter valid hosts. Then you can test sending notifications to remote hosts.

rake test:remote_notification

Examples

Simple

require 'growl_ssh_notifier'

rec = GrowlSSHNotifier::Receiver.new("localhost")
rec.send_notification('Test Message', 'This is a test message sent to the LOCALHOST machine with GrowlSSHNotifier.')

Notification with Icon

require 'growl_ssh_notifier'

rec = GrowlSSHNotifier::Receiver.new("localhost", { :application_icon => 'Mail' })
rec.send_notification('Test Message', 'This is a test message sent to the LOCALHOST machine with GrowlSSHNotifier.')

License

This package is licensed under the MIT license and/or the Creative Commons Attribution-ShareAlike.

About

Send Growl (mac) notifications using SSH

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages