Hello Rack
What is Rack?
Rack provides a minimal, modular and adaptable interface for developing web applications in Ruby. By wrapping HTTP requests and responses in the simplest way possible, it unifies and distills the API for web servers, web frameworks, and sof...
Written by Sean Behan on 06/17/2012
How To Create Blurry Background Images Programmatically from the Command Line or with Ruby
Turn this
into this
You can use ImageMagick to make blurry images.
To install with Homebrew on OS X.
brew install imagemagick
After installing you can run from the command line
convert yourimage.png -channel RGBA -blu...
Written by Sean Behan on 08/24/2013
Renaming Routes in Rails 3 with :As and :Controller
Renaming routes in Rails 2.* is straight forward. It goes something like this.
## config/routes.rb
map.resources :users, :as => :members
This will give you users_path and form_for(User.new) helpers, for instance, mapping the url to /members instead of ...
Written by Sean Behan on 06/17/2012
Add User Directories to Apache2 Web Server
You can either link up the modules yourself like this:
ln -s /etc/apache2/mods-available/userdir.conf /etc/apache2/mods-enabled/userdir.conf
ln -s /etc/apache2/mods-available/userdir.load /etc/apache2/mods-enabled/userdir.load
Or you can use the Apach...
Written by Sean Behan on 06/17/2012
Disk Usage Information on Mac OS X
Get disk usage information about the Desktop
$ du -h -d 0 Desktop
14G Desktop
Information about how much free space is available on computer
$ df -lh
Filesystem Size Used Avail Capacity Mounted on
/dev/disk0s2 111Gi 109Gi 2.3Gi 98% /
...
Written by Sean Behan on 06/17/2012