Skip to content

Instantly share code, notes, and snippets.

View nclark's full-sized avatar
💭
wu tang is for the children

Neal Clark nclark

💭
wu tang is for the children
View GitHub Profile
@nclark
nclark / gitconfig
Created January 18, 2010 23:10 — forked from Lytol/gist:280458
.gitconfig
[user]
email = <your-email>
name = <your-name>
[color]
diff = auto
status = auto
branch = auto
[alias]
st = status
co = checkout
*.pbxproj -crlf -diff -merge
@nclark
nclark / ultemplate.rb
Created October 24, 2011 21:06 — forked from Lytol/ultemplate.rb
Rails 3 Application Template
# Rails application template for Rails 3 + Postgres + Git + haml + JQuery + Rspec + Cucumber + Capybara + FactoryGirl
# by Brian Smith <bsmith@swig505.com>
# Create a default README
file "README.md", <<-EOF
#{app_name}
#{"=" * app_name.length}
TODO: description
@nclark
nclark / .osx
Created December 18, 2011 20:04 — forked from dennmart/.osx
Sensible defaults for Mac OS X Lion
# Enable full keyboard access for all controls (e.g. enable Tab in modal dialogs)
defaults write NSGlobalDomain AppleKeyboardUIMode -int 3
# Enable the 2D Dock
defaults write com.apple.dock no-glass -bool true
# Make Dock icons of hidden applications translucent
defaults write com.apple.dock showhidden -bool true
# Disable menu bar transparency
@nclark
nclark / run
Created May 18, 2012 22:01 — forked from riywo/run
unicorn with daemontools
#!/bin/bash
# mkdir /service/redmine-unicorn
# cd /service/redmine-unicorn
# mkdir env
# echo "production" > env/RAILS_ENV
# echo "/home/riywo/redmine" > env/RAILS_ROOT
# echo "/home/riywo/.rbenv" > env/RBENV_ROOT
# echo "riywo" > env/USER
exec 2>&1 \

Here's what you get.

Some CoffeeScript (verbosely commented for clarity)

# Override Rails handling of confirmation

$.rails.allowAction = (element) ->
  # The message is something like "Are you sure?"
  message = element.data('confirm')