Search
Categories
Ad

Archive for November, 2009

mw: printing variables to Growl using Meow

Sunday, November 29th, 2009
mw

mw

Today I uploaded a new Rubygem called “mw” (pronounced as [mi'u]).

mw is a tiny useful library to output the result of pp to Growl.The original idea of Growl printing comes from jugyo’s g. Though the concept is great, g does not work on my environment. I’ve got “connection errors” from Growl.
I suspect that “ruby-growl” library on my machine does not work well.

Anyway, to overcome this problem, I reinvented the same feature using Meow, a Growl notification wrapper for the rb-cocoa environment.

INSTALL

First, you need to be a Mac-user, and have installed rb-cocoa.

port install rb-cocoa

Sinece I uploaded mw.gem to gemcutter.org, installing mw is as easy as

gem install gemcutter
gem tumble
gem install mw

USAGE

require 'mw'
mw "message"
mw YourClass.new

To change priority, you can use mw1~5. (mw3 is normal, mw1 is the lowest, and mw5 is the highest. mw4 and mw5 will fire the sticky notes, so that the note will live on your screen persitently.

begin
do_dangerous_and_raise_some_exception
rescue => e
mw4 e
end

SOURCES

all the sources can be seen at http://github.com/tomoya55/mw.

NOTES

1. If you are still not sure what mw is, please take a look at jugyo’s presentation of g.

2. My mw requires rb-cocoa and meow. If you runs ruby on Linux or Windows, you cannot use this library. use g instead.

2 must-have SIMBL extensions for using Terminal on OSX Leopard

Saturday, November 7th, 2009

Yes, SnowLeopard is already out. But most of users including me still loves Leopard, right ?

In this small article, I would like to introduce 2 useful extensions for Terminal.app

1. Visor

With Visor, you can always show Terminal by typing one HotKey. Visor makes Terminal.app invisible when you don’t use, and makes it visible when you need. This is a great application if you are one of CUI freaks!

2. TerminalColoreopard

091107-0001

With TerminalColoreopard, you can change your color settings of ANSI colors in Terminal easily via OSX’s default Color dialog. I strongly recommend to use Adobe Kuler or see the entry “Terminal color schemes for .Xdefaults or .Xresources file” to arrange nice color combinations.