Skip to content

Instantly share code, notes, and snippets.

int d = [[n toStringWithDecimalPlaces:0] length];
if (d > decimals) decimals = d;
@esad
esad / pong.rb
Created May 23, 2009 01:35
Sketch for a game of pong in kyoto
require 'kyoto'
use 'actors/velocity'
use 'actors/bound_to_world'
use 'game/pausable'
use 'game/score'
use 'color'
use 'collision_detection'
class Paddle < Actor
@esad
esad / rgp.rb
Created February 13, 2009 19:47
#!/usr/bin/ruby
#
# Recursive git pull - will go into first-level subdirectories that are git repos and execute "git pull", stopping on first unsuccessful pull
# @Copyleft 2009 Esad Hajdarevic <[email protected]> http://dev.soup.io/
repos = Dir["*/.git"].map {|path| path.chomp!("/.git") }
if repos.empty?
puts "No git repositories found"
else