https://github.com/thoughtbot/laptop | thoughtbot/laptop https://github.com/thoughtbot/dotfiles | thoughtbot/dotfiles https://github.com/jetrockets/attrio | jetrockets/attrio https://www.solanolabs.com/product | Solano Labs | Product http://robots.thoughtbot.com/post/56828751507/how-to-create-postgres-indexes-concurrently-in | How to Create Postgres Indexes Concurrently in ActiveRecord Migrations http://robots.thoughtbot.com/post/55689359336/the-perils-of-uniqueness-validations | The Perils of Uniqueness Validations https://github.com/trptcolin/consistency_fail | trptcolin/consistency_fail http://dansowter.com/mailman-guide/ | dansowter.com | Mailman Guide https://discussions.apple.com/thread/4932384?start=0&tstart=0 | Quicktime Screen Recording Makes Green...: Apple Support Communities http://www.timseverien.nl/promin/ | Promin - sexy forms
This file contains hidden or 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
# Dump | |
pg_dump -U username -W -h localhost dbname -f dump.sql | |
# Import | |
psql -U username -h localhost dbname -f /home/username/dump.sql |
This file contains hidden or 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
GET http://subdomain.exampleapp.dev/api/deals/7589 | |
Header Authorization token xyz123 | |
Headers | |
Cache-Control: max-age=0, private, must-revalidate | |
Connection: Keep-Alive | |
Content-Type: application/json; charset=utf-8 | |
Date: Tue, 11 Dec 2012 09:28:01 GMT | |
Etag: "b6b44c59b785dcbc6349fe31129f00b0" |
This file contains hidden or 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
Started GET "/api/deals/7589" for 127.0.0.1 at 2012-12-11 20:33:13 +1100 | |
Processing by Api::V1::DealsController#show as JSON | |
Parameters: {"id"=>"7589"} | |
User Load (0.5ms) SELECT "users".* FROM "users" WHERE "users"."account_id" = 6 AND "users"."id" = 8 LIMIT 1 | |
Opro::Oauth::AuthGrant Load (0.3ms) SELECT "opro_auth_grants".* FROM "opro_auth_grants" WHERE "opro_auth_grants"."access_token" = '25ab40012c839451914aa69eef3c077a' LIMIT 1 | |
User Load (0.4ms) SELECT "users".* FROM "users" WHERE "users"."account_id" = 6 AND "users"."id" IN (8) | |
Opro::Oauth::ClientApp Load (0.2ms) SELECT "opro_client_apps".* FROM "opro_client_apps" WHERE "opro_client_apps"."id" IN (1) | |
Account Load (0.2ms) SELECT "accounts".* FROM "accounts" WHERE "accounts"."id" = $1 LIMIT 1 [["id", 6]] | |
CACHE (0.0ms) SELECT "accounts".* FROM "accounts" WHERE "accounts"."id" = $1 LIMIT 1 [["id", 6]] | |
AppNotice Load (0.2ms) SELECT "app_notices".* FROM "app_notices" |
This file contains hidden or 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 Api | |
module V1 | |
class DealsController < ApplicationController | |
respond_to :json | |
allow_oauth! | |
before_filter :authenticate_user! | |
load_and_authorize_resource | |
def index | |
respond_with Deal.all |
This file contains hidden or 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
/scripts/ftpquotacheck --force |
This file contains hidden or 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 'spec_helper' | |
feature 'import xls spreadsheet of members' do | |
scenario 'importing members from spreadsheet' do | |
pending | |
end | |
scenario 'importing members from spreadsheet with errors' do | |
pending |
This file contains hidden or 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
# /etc/nginx/sites-enabled/berlin | |
upstream spree.ryanbigg.com { | |
# fail_timeout=0 means we always retry an upstream even if it failed | |
# to return a good HTTP response (in case the Unicorn master nukes a | |
# single worker for timing out). | |
# for UNIX domain socket setups: | |
server unix:/tmp/berlin.socket fail_timeout=0; | |
} |
This file contains hidden or 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
%ul.social-share | |
%li.text Share on: | |
%li | |
- summary = "#{@gallery.title} #{@gallery.gallery_type} #{@gallery.subtitle}" | |
- link = "http://www.facebook.com/sharer/sharer.php?s=100&p[url]=#{url_encode(request.url)}&p[images][0]=&p[title]=#{url_encode(@gallery.title)}&p[summary]=#{url_encode(summary)}" | |
= link_to link, target: "_blank" do | |
%i.icon-facebook | |
%li | |
- status = "#{@gallery.title} #{@gallery.gallery_type} #{@gallery.subtitle}" | |
- link = "http://twitter.com/home?status=#{url_encode(status)}" |