This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
location ~ ^/(assets|images|javascripts|stylesheets|swfs|system)/ { | |
gzip_static on; | |
expires max; | |
add_header Cache-Control public; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
defaults write com.apple.NetworkBrowser EnableODiskBrowsing -bool true | |
defaults write com.apple.NetworkBrowser ODSSupported -bool true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"color_scheme": "Packages/Color Scheme - Default/Twilight.tmTheme", | |
"font_size": 13.0, | |
"ensure_newline_at_eof_on_save": true, | |
"tab_size": 2, | |
"translate_tabs_to_spaces": true, | |
"trim_trailing_white_space_on_save": true | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
source "http://rubygems.org" | |
gem 'httpi', :git => 'git://github.com/bensie/httpi.git', :branch => 'ntlm' | |
gem 'savon' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def auth | |
@auth ||= Rack::Auth::Basic::Request.new(request.env) | |
end | |
def current_user | |
@current_user | |
end | |
def authenticated? | |
request.env['REMOTE_USER'] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Contact | |
attr_accessor :name | |
end | |
class Person < Contact | |
attr_accessor :title |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bash -c ' | |
if [ ! -f /usr/bin/chef-client ]; then | |
apt-get update | |
apt-get install -y build-essential bison openssl libreadline6 libreadline6-dev curl git-core zlib1g zlib1g-dev libssl-dev libyaml-dev libsqlite3-0 libsqlite3-dev sqlite3 libxml2-dev autoconf libc6-dev | |
bash < <(curl -s https://rvm.beginrescueend.com/install/rvm) | |
( | |
cat <<'EOP' | |
[[ -s "/usr/local/rvm/scripts/rvm" ]] && source "/usr/local/rvm/scripts/rvm" # This loads RVM into a shell session. | |
EOP |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Person | |
attr_accessor :name, :title | |
def first_name | |
name.split[0] | |
end | |
def last_name | |
name.split[1] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Person | |
attr_accessor :name, :title | |
def first_name | |
name.split[0] | |
end | |
def last_name | |
name.split[1] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/Users/jkmiller/.rvm/gems/ruby-1.9.2-p180/bundler/gems/rails-b3791da0318e/activesupport/lib/active_support/dependencies.rb:477:in `load_missing_constant': Admin is not missing constant Account! (ArgumentError) | |
from /Users/jkmiller/.rvm/gems/ruby-1.9.2-p180/bundler/gems/rails-b3791da0318e/activesupport/lib/active_support/dependencies.rb:181:in `block in const_missing' | |
from /Users/jkmiller/.rvm/gems/ruby-1.9.2-p180/bundler/gems/rails-b3791da0318e/activesupport/lib/active_support/dependencies.rb:179:in `each' | |
from /Users/jkmiller/.rvm/gems/ruby-1.9.2-p180/bundler/gems/rails-b3791da0318e/activesupport/lib/active_support/dependencies.rb:179:in `const_missing' | |
from /Users/jkmiller/.rvm/gems/ruby-1.9.2-p180/bundler/gems/rails-b3791da0318e/activesupport/lib/active_support/inflector/methods.rb:124:in `block in constantize' | |
from /Users/jkmiller/.rvm/gems/ruby-1.9.2-p180/bundler/gems/rails-b3791da0318e/activesupport/lib/active_support/inflector/methods.rb:123:in `each' | |
from /Users/jkmiller/.rvm/gems/ruby-1.9.2-p18 |