Skip to content

Instantly share code, notes, and snippets.

View paolochiodi's full-sized avatar

Paolo Chiodi paolochiodi

View GitHub Profile
jQuery.fn.equalHeights = function() {
return this.height(Math.max.apply(null,
this.map(function() {
return jQuery(this).height()
}).get()
));
};
// Clears white-space text nodes...
// TODO: check CSS white-space property instead of "pre" nodeName.
function clearWSNodes(ctx) {
ctx = ctx || document;
var node = ctx.firstChild,
oNode,
prnt,
@tejo
tejo / bootstrap.rb
Created December 26, 2009 12:36
bootstrap
# require webrat , responders & database_cleaner gems
############## plugin commands #################
plugin 'paperclip', :git => "git://github.com/thoughtbot/paperclip.git"
plugin 'rails_indexes', :git => 'git://github.com/eladmeidar/rails_indexes.git'
plugin 'formtastic', :git => 'git://github.com/justinfrench/formtastic.git'
plugin 'scrooge', :git => 'git://github.com/methodmissing/scrooge.git'
plugin 'web-app-theme', :git => 'git://github.com/pilu/web-app-theme.git'
plugin 'admin_section', :git => 'git://github.com/tejo/admin_section.git'
@vjt
vjt / awesome-nginx.conf
Created January 31, 2011 19:43
*AWESOME* nginx configuration for Ruby/Rack web applications
#
# mmm m m mmm mmm mmm mmmmm mmm
# " # "m m m" #" # # " #" "# # # # #" #
# m"""# #m#m# #"""" """m # # # # # #""""
# "mm"# # # "#mm" "mmm" "#m#" # # # "#mm"
#
# nginx configuration For Ruby/Rack web applications
#
# Cooked up with style, care and a bit of *secret*
# nerdy spice. :-)
# Extend jQuery objects with Underscore collection methods.
#
# Each collection method comes in two flavors: one prefixed
# with _, which yields a bare DOM element, and one prefixed
# with $, which yields a jQuery-wrapped element.
#
# So if `this` is a jQuery object, instead of:
#
# _.max @, (el) -> $(el).height()
#
@erikh
erikh / hack.sh
Created March 31, 2012 07:02 — forked from DAddYE/hack.sh
OSX For Hackers
#!/usr/bin/env sh
##
# This is script with usefull tips taken from:
# https://github.com/mathiasbynens/dotfiles/blob/master/.osx
#
# install it:
# curl -sL https://raw.github.com/gist/2108403/hack.sh | sh
#