Skip to content

Instantly share code, notes, and snippets.

#!/usr/bin/env ruby
puts 'Hello World'
#!/usr/bin/ruby
STDOUT.sync = true
bars = ['/','-','\\','|']
i=1
while i do
print "\rrunning #{bars[i%4]}"
i += 1
sleep 0.5
end
#!/usr/bin/env ruby
# Non-Copyright (c) 2008 Joao Paulo Camargo <github@jotape.org>
#
# moourl.rb - is a small module to get contracted urls using http://moourl.com
#
# Usage:
# MooUrl::milk('http://code.jotape.org')
# > http://moourl.com/foxvd
# MooUrl::moo('foxvd')
# > http://code.jotape.org