Skip to content

Instantly share code, notes, and snippets.

@JohnPlummer
JohnPlummer / header-bar.css
Created May 12, 2011 12:08
HTML5 WordPress Header
#header-bar {
height: 10px;
background: #1F1F1F;
-moz-box-shadow: 0 0 25px 5px rgba(0,0,0,0.5);
-webkit-box-shadow: 0 0 25px 5px rgba(0,0,0,0.5);
box-shadow: 0 0 25px 5px rgba(0,0,0,0.5);
}
@JohnPlummer
JohnPlummer / current_page_item.css
Created May 4, 2011 20:25
HTML5 Wordpress Footer
#nav-footer ul li.current_page_item > a {
pointer-events: none;
cursor: default;
color: #BED730;
}
@JohnPlummer
JohnPlummer / style.css
Created April 21, 2011 13:33
Customising Roots Theme
/*
Theme Name: Roots Child
Template: Roots
*/
@import url("../roots/style.css");
@JohnPlummer
JohnPlummer / compass.rb
Created April 14, 2011 16:00
Rails, Compass, and Heroku
require 'compass'
require 'compass/app_integration/rails'
require 'fileutils'
FileUtils.mkdir_p(Rails.root.join("tmp", "stylesheets"))
Compass::AppIntegration::Rails.initialize!
Rails.configuration.middleware.delete('Sass::Plugin::Rack')
Rails.configuration.middleware.insert_before('Rack::Sendfile', 'Sass::Plugin::Rack')
@JohnPlummer
JohnPlummer / stop.rb
Created February 23, 2011 11:59
Stop in rails console if something fails in cucumber test. From http://railsdog.com/blog/2011/02/22/cucumber-testing-tips/ (Neeraj Singh)
# Usage:
# @wip @stop
# At the end of features/support/env.rb add the following line
# require File.expand_path(File.dirname(__FILE__) + '/stop')
# $ cucumber -p wip
After do |scenario|
if scenario.failed? && scenario.source_tag_names.include?("@wip") && scenario.source_tag_names.include?("@stop")
puts "Scenario failed. You are in rails console becuase of @stop. Type exit when you are done"
@JohnPlummer
JohnPlummer / authentication.feature
Created January 31, 2011 16:21
Authentication with devise - Features
Feature: Authentication
So that users can be associated with an account
As the site owner
I want users to login
@JohnPlummer
JohnPlummer / Gemfile
Created January 21, 2011 14:36
Add authentication with devise - install and configure
source 'http://rubygems.org'
gem 'rails', '3.0.3'
gem 'sqlite3-ruby', :require => 'sqlite3'
gem 'haml'
gem 'jquery-rails'
# Authentication
gem 'devise', :git => "git://github.com/JohnPlummer/devise.git"
@JohnPlummer
JohnPlummer / .autotest
Created January 18, 2011 13:56
Rails Setup
require "autotest/growl"
require "autotest/fsevent"
Autotest.add_hook :initialize do |autotest|
%w{.git .svn .hg .DS_Store ._* vendor tmp log doc}.each do |exception|
autotest.add_exception(exception)
end
end
<FileZilla3>
<Settings>
<Setting name="Config Location">/Users/[Username]/Dropbox/Config/Preferences/filezilla/</Setting>
<Setting name="Kiosk mode">0</Setting>
<Setting name="Disable update check">0</Setting>
</Settings>
<Servers>
</Servers>
</FileZilla3>
# mute startup chime
sudo nvram SystemAudioVolume=%80
# reenable startup chime.
sudo nvram -d SystemAudioVolume