Some exercises from the Falsy Values workshops.
The good parts:
- HTTP server and client in same script
- Express cookies example
- Express routing example
- Express error handling
- Express middlewares example
- Simple HTTP proxy
# config.gem "rspec", :lib => false, :version => ">=1.2.6" unless File.directory?(File.join(Rails.root, 'vendor/plugins/rspec')) | |
# config.gem "rspec-rails", :lib => 'spec/rails', :version => ">=1.2.6" unless File.directory?(File.join(Rails.root, 'vendor/plugins/rspec-rails')) |
set :application, "example.com" | |
set :deploy_to, "/var/www/#{application}" | |
role :app, "example.com" | |
role :web, "example.com" | |
role :db, "example.com", :primary => true | |
set :scm, :git | |
set :repository, "ssh://[email protected]/git/example.com" | |
set :branch, "origin/master" |
require 'digest/sha1' | |
module EasyAuth | |
# http://techspeak.plainlystated.com/2010/03/drop-dead-simple-authentication-for.html | |
# To generate a hashed password (in irb): | |
# require 'easy_auth' | |
# EasyAuth.hash('my_password') # Put this in AUTHORIZED_USERS | |
AUTHORIZED_USERS = { |
# This works with steak 0.3.x and rspec 1.x | |
# For steak --pre and rspec 2 see this fork: http://gist.github.com/448487 | |
# Put this code in acceptance_helper.rb or better in a new file spec/acceptance/support/javascript.rb | |
Spec::Runner.configure do |config| | |
config.before(:each) do | |
Capybara.current_driver = :selenium if options[:js] | |
end |
Some exercises from the Falsy Values workshops.
The good parts:
#!/bin/bash | |
# +----------------------------------------------------------------------+ | |
# | | | |
# | Mount the root file system / with the option noatime | | |
# | | | |
# | By Philipp Klaus <http://blog.philippklaus.de> | | |
# | Tip found on <http://blogs.nullvision.com/?p=275> | | |
# | | | |
# +----------------------------------------------------------------------+ |
Pod::Spec.new do |s| | |
s.name = 'TestFlightSDK' | |
s.version = '1.1b1' | |
s.license = 'Commercial' | |
s.summary = 'TestFlightSDK for over-the-air beta testing and crash reporting.' | |
s.homepage = 'http://www.testflightapp.com' | |
s.author = { 'TestFlight' => '[email protected]' } | |
s.source = { :http => 'https://d3fqheiq7nlyrx.cloudfront.net/sdk-downloads/TestFlightSDK1.1beta1.zip' } | |
s.description = 'TestFlightSDK for over-the-air beta testing and crash reporting.' | |
s.platform = :ios |
This script installs a patched version of ruby 1.9.3-p327 with boot-time performance improvements (#66 and #68), and runtime performance improvements (#83 and #84). It also includes the new backported GC from ruby-trunk.
Many thanks to funny-falcon for the performance patches.
This installs a patched ruby 1.9.3-p385 with various performance improvements and a backported COW-friendly GC, all courtesy of funny-falcon.
You will also need a C Compiler. If you're on Linux, you probably already have one or know how to install one. On OS X, you should install XCode, and brew install autoconf
using homebrew.
apt-get install make git g++ gcc zlib1g zlib1g-dev libxml2 libxml2-dev -y | |
# https://developers.google.com/speed/webp/docs/compiling#building | |
cd /usr/local/src | |
wget http://downloads.webmproject.org/releases/webp/libwebp-0.4.3.tar.gz | |
tar -xvzf libwebp-0.4.3.tar.gz | |
cd libwebp-0.4.3 | |
./configure |