Here are some resources that I found helpful and found inspiration from when I was writing the talk.
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
alias gh="open \`git remote -v | grep [email protected] | grep fetch | head -1 | cut -f2 | cut -d' ' -f1 | sed -e's/:/\//' -e 's/git@/http:\/\//'\`" |
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
@import "compass/utilities/general/clearfix"; | |
$gutter-width: 10px; // All grids systems have the same gutter width | |
$float-direction: left; | |
$left-gutter-width: ceil($gutter-width / 2) !default; | |
$right-gutter-width: $gutter-width - $left-gutter-width !default; | |
$base-line-height: 21px; | |
$show-grid-background: false; | |
@mixin centered { |
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
.two-columns { | |
overflow: hidden; | |
*zoom: 1; | |
position: relative; | |
} | |
.two-columns .column-one, .two-columns .column-two { | |
-moz-box-sizing: border-box; | |
-webkit-box-sizing: border-box; | |
-ms-box-sizing: border-box; |
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
# app/metal/wordpress_attacks.rb | |
# | |
# Remember to add sinatra to your Gemfile. | |
require 'sinatra/base' | |
class WordPressAttacks < Sinatra::Base | |
helpers do | |
def youtube_movie_url | |
"http://www.youtube.com/watch?v=EDcWCGdr-wE" |
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
module Sass::Script::Functions | |
def user_color | |
color_values = options[:custom][:user].color. | |
scan(/^#?(..?)(..?)(..?)$/).first. | |
map {|num| num.ljust(2, num).to_i(16)} | |
Sass::Script::Color.new(color_values) | |
end | |
end |
With Rails 3.0 released a few weeks ago I've migrated a few apps and I'm constantly finding useful new improvements. One such improvement is the ability to log anything in the same way that Rails internally logs ActiveRecord and ActionView. By default Rails 3 logs look slightly spiffier than those produced by Rails 2.3: (notice the second line has been cleaned up)
Started GET "/" for 127.0.0.1 at Mon Sep 06 01:07:11 -0400 2010
Processing by HomeController#index as HTML
User Load (0.2ms) SELECT `users`.* FROM `users` WHERE (`users`.`id` = 3) LIMIT 1
CACHE (0.0ms) SELECT `users`.* FROM `users` WHERE (`users`.`id` = 3) LIMIT 1
Rendered layouts/_nav.html.erb (363.4ms)