Skip to content

Instantly share code, notes, and snippets.

View revans's full-sized avatar
🤠
Building Businesses

Robert Evans revans

🤠
Building Businesses
View GitHub Profile
@revans
revans / Bluepill Uncorn Config File
Created May 18, 2011 02:05
Bluepill used at Halftoneapp.com
#
# Halftoneapp.com Sample Bluepill Configuration File
# Read more at: http://blog.halftoneapp.com
#
# Set paths
home_dir = "/home/railsapp"
rails_shared = "#{home_dir}/app/shared"
unicorn_path = "/path/to/unicorn_rails"
@revans
revans / seed.rb
Created May 25, 2011 02:26
Rails Seed Management, Migration style
# I use the colored gem to give colored output to stdout
#
# The 'attention' method is for a standard output to the console to update the developer
# on what seed was ran.
#
# The last command loads all seed files from the db/seeds/ directory. Typically, I name my files in there like so:
#
# 001_create_account.rb
# 002_create_users.rb
# 003_create_tasks.rb
@revans
revans / app.rb
Created May 25, 2011 02:31
Application File located in the lib directory of a Rails project.
require 'colored'
module App
class Project
class << self
def name
'Project Name'
end
def domain
@revans
revans / gist:1133370
Created August 9, 2011 03:54
Kilauea burger
What it is: jalapeno and black pepper crusted burger, pepper jack cheese, chipotle aioli and seasond red onion strings. Here is how you make it.
First the meat for the burger. Usually they are grilled. If you don't have a possibility to charcoal grill them, ..then pan grill.
1/2 lb. ground beef sirloin (92% lean)
1/2 lb. ground beef chuck (85% lean)
salt to taste
1 tablespoons cracked black pepper
1 or 1 1/2 tablespoon very finely diced jalapeno
6 hamburger buns, split
1 pound ground lamb
1/2 cup very finely chopped (or shredded) onion
2 teaspoons fresh minced garlic
3/4 teaspoon sea salt
1/2 teaspoon dried ground marjoram
1/2 teaspoon dried ground rosemary
1/4 teaspoon black pepper
Mix everything together and let sit in the fridge for 1-2 hours.
Blend in a food processor for about 1 minute. (When cooked, this will help give it a more traditional gyro feel on your palate. Otherwise, it just takes like cooked minced meat.)
Form into an oblong around a spit, and slow cook over a grill for around 30-45 minutes, cooking far from the coals, and rotating slowly. Alternatively, bake in the oven in a meatloaf shape for about 45 minutes to 1 hour, at 325 degrees F. It should be a bit dry.
@revans
revans / pryrc
Created August 31, 2011 21:13
pryrc
# Load plugins (only those I whitelist)
Pry.config.should_load_plugins = false
Pry.plugins["doc"].activate!
begin
require 'awesome_print'
Pry.config.print = proc { |output, value| output.puts value.ai }
rescue LoadError => err
puts "no awesome_print :("
end
@revans
revans / gist:1189555
Created September 2, 2011 19:13 — forked from voodootikigod/gist:1155790
PyCodeConf Ticket Give-away
Day job: Code Wranglers
Favorite Python project: pystache
Favorite Conference: CodeConf
Python Experience Level: Beginner
@revans
revans / USAGE.md
Created September 12, 2011 15:01 — forked from kossnocorp/USAGE.md
MacVim with Drawer compile manual

Clone & Build

curl https://raw.github.com/gist/1211490/afc8c6ff2221fced522388a4220397c1a7c5ece3/build.sh | sh
@revans
revans / gist:1293745
Created October 17, 2011 20:47 — forked from fennb/gist:1283573
nginx microcaching config example
# Set cache dir
proxy_cache_path /var/cache/nginx levels=1:2
keys_zone=microcache:5m max_size=1000m;
# Virtualhost/server configuration
server {
listen 80;
server_name yourhost.domain.com;
# Define cached location (may not be whole site)
@revans
revans / gist:1305668
Created October 22, 2011 05:17
Ruby 1.9.2, Rails 3.1
ruby-1.9.2-p290 :001 > Date.today
=> Fri, 21 Oct 2011
ruby-1.9.2-p290 :002 > Date.yesterday
=> Fri, 21 Oct 2011
ruby-1.9.2-p290 :003 > Date.tomorrow
=> Sun, 23 Oct 2011