Skip to content

Instantly share code, notes, and snippets.

View steveclarke's full-sized avatar

Steve Clarke steveclarke

View GitHub Profile
@steveclarke
steveclarke / TechDecisions.md
Created April 14, 2012 13:55
Choices to make in a new Rails project. Would love to see this forked with other's opinions.

Team Support

Source Code Control

BitBucket
Alternative: GitHub, private git

Time Tracking

Pivotal Tracker

@steveclarke
steveclarke / gist:2384616
Created April 14, 2012 13:57 — forked from panicsteve/gist:1641705
Form letter template for acquired startups
Dear soon-to-be-former user,
We've got some fantastic news! Well, it's great news for us anyway. You, on
the other hand, are screwed.
We've just been acquired by:
[ ] Facebook
[ ] Google
[ ] Twitter
@steveclarke
steveclarke / gist:2387362
Created April 14, 2012 19:37
Diff using sub-processes
diff -u <(curl www.google.com | tidy) <(curl www.google.ca | tidy) | view -
@steveclarke
steveclarke / gist:2392489
Created April 15, 2012 12:30
Map a key to run the open file through Ruby
:map ,r :w\!ruby %<cr>
@steveclarke
steveclarke / Contract Killer 3.md
Created December 5, 2012 15:54
The latest version of my ‘killer contract’ for web designers and developers

Contract Killer 3

Revised date: 07/11/2012

Between us [company name] and you [customer name]

Summary:

We’ll always do our best to fulfil your needs and meet your expectations, but it’s important to have things written down so that we both know what’s what, who should do what and when, and what will happen if something goes wrong. In this contract you won’t find any complicated legal terms or long passages of unreadable text. We’ve no desire to trick you into signing something that you might later regret. What we do want is what’s best for both parties, now and in the future.

/**
* Vertical centering with Flexbox + margin fallback
* Lea Verou & David Storey
*/
html, body { height: 100%; }
body {
width: 100%; /* needed for FF */
margin: 0;
@steveclarke
steveclarke / dabblet.css
Created December 26, 2012 17:26
The first commented line is your dabblet’s title
/**
* The first commented line is your dabblet’s title
*/
background: #f06;
background: linear-gradient(45deg, #f06, yellow);
min-height: 100%;
=Navigating=
visit('/projects')
visit(post_comments_path(post))
=Clicking links and buttons=
click_link('id-of-link')
click_link('Link Text')
click_button('Save')
click('Link Text') # Click either a link or a button
click('Button Value')
@steveclarke
steveclarke / seventemplate.rb
Last active December 15, 2015 15:19
generator for default Rails project
gem 'thin'
gem 'sevenhelpers', git: 'https://github.com/sevenview/sevenhelpers.git'
#gem_group :assets do
# gem 'zurb-foundation', '~>4.0.0'
#end
gem_group :test, :development, :staging do
gem 'factory_girl_rails', '~> 4.2'
gem 'ffaker'
worker_processes Integer(ENV["WEB_CONCURRENCY"] || 3)
timeout 15
preload_app true
before_fork do |server, worker|
Signal.trap 'TERM' do
puts 'Unicorn master intercepting TERM and sending myself QUIT instead'
Process.kill 'QUIT', Process.pid
end