Skip to content

Instantly share code, notes, and snippets.

View rafmagana's full-sized avatar

Rafael Magaña rafmagana

  • Colima, Mexico
View GitHub Profile
screen -X eval 'hardstatus alwayslastline "%{r}[%{w}%n%{r}]"' # this sets the hardstatus to [0], where 0 is the number of window
require 'rubygems'
require 'prowly'
Prowly.notify do |n|
n.apikey = "your_apikey_here"
n.priority = Prowly::Notification::Priority::MODERATE
n.application = "My Site"
n.event = "Alert"
n.description = "Something went wrong!"
end
require 'rubygems'
require 'active_record'
require 'active_record/schema_dumper'
ActiveRecord::Base.establish_connection(
:adapter => "mysql",
:host => "localhost",
:username => "root",
:password => "pwd",
:database => "test"
class Foo
def splat(bar, baz)
[bar, baz]
end
end
class Bar < Foo
def splat(*)
#do whatever you want here, like logging, etc
super