- Only keep the members who need to do something (blocking) the card on the card. Not everyone involved. After you do your part, take yourself off the card, and possibly add someone else to the card if it's their turn. It's important that all the cards with your face on it need you to do something. No false-positives.
- If you need someone's opinion on a card but they don't have to do something, just mention in a comment
- The description is the current state of the task, not a history of the evolution of the task. Comments are a history of the discussion that yields the description
- Use labels to indicate the kind of card, not state (e.g. "bug" but not "in qa"). Alternatively, have a code system in the card title. For example, we process data in batches. Batches have one to two letters to indicate client and numbers that increment. So IS42 is Internal Sales batch #42. This is nice when the label needs to be a little different each time. Instead of a label, put it at the beginning of the title.
- Use
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
# Docker | |
function docker-cleanup { | |
# Find all containers that have exited | |
containers=`docker ps -a -q -f status=exited | xargs` | |
if [[ $containers ]]; then | |
# Remove exited containers | |
docker rm $containers | |
else | |
echo "No containers to remove" | |
fi |
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
require 'active_support' | |
require 'active_support/core_ext/object/json' | |
class Person | |
def initialize(name, age, car) | |
@name = name | |
@age = age | |
@car = car | |
@birthyear = compute_birth_year | |
end |
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
package athena | |
import ( | |
accountant "codeship-accountant", | |
janus "codeship-janus", | |
ares "ares-api" | |
) | |
func main() { | |
// codeship accountant implements accountant interface |
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
#!/usr/bin/env bash | |
# Usage: restart-last-build <project-id> | |
# You must set the environment variable API_KEY to your codeship API key, for example: | |
# $ CODESHIP_API_KEY=abc123 restart-last-build 1234 | |
PROJECT_ID=$1 | |
set -e | |
echo Restarting last build for project $PROJECT_ID |
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
tea $("#person"), | |
name: "Nick", | |
bio: "Coderguy" |
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
# Merging Scopes | |
# ============== | |
# The goal is to join two tables to get all the records where a scope on both | |
# side of the join is used. I used to do this with a `where()` in which I | |
# added some sql on the joined table. But, I wanted to use the existing scopes | |
# from the joining table. Turns out there's a `merge` method on a scope where | |
# you can merge with another scope without having to chain! | |
class Car < ActiveRecord::Base | |
has_and_belongs_to_many :people |
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
class ApplicationController < ActionController::Base | |
rescue_from StandardError, with: :handle_exception | |
def squeak(*args) | |
SqueakyMailer.notification(*args).deliver | |
end | |
def handle_exception(e) | |
squeak( | |
message: "Error: #{e.message}", |
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
#!/usr/bin/env ruby | |
# From: http://ngauthier.com/2014/06/scraping-the-web-with-ruby.html | |
require 'capybara' | |
require 'capybara/poltergeist' | |
require 'csv' | |
require 'gdbm' | |
class NickBot | |
include Capybara::DSL |
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
#!/usr/bin/env ruby | |
require_relative '../config/environment' | |
Bundler.require :bot | |
name = ARGV[1] | |
csv = "#{name}.csv" | |
bot = Bink.new csv | |
command = ARGV[0] |