Skip to content

Instantly share code, notes, and snippets.

Joshua Canfield jcanfield

Block or report user

Report or block jcanfield

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@dwabnitz
dwabnitz / revised-font-stack.css
Created Aug 2, 2010 — forked from jonbuda/revised-font-stack.css
A Revised Web Font Stack Selection
View revised-font-stack.css
/*
A Revised Font Stack
from A Way Back
http://www.awayback.com/revised-font-stack/
*/
/*
@isaacs
isaacs / node-and-npm-in-30-seconds.sh
Last active Feb 18, 2020
Use one of these techniques to install node and npm without having to sudo. Discussed in more detail at http://joyeur.com/2010/12/10/installing-node-and-npm/ Note: npm >=0.3 is *safer* when using sudo.
View node-and-npm-in-30-seconds.sh
echo 'export PATH=$HOME/local/bin:$PATH' >> ~/.bashrc
. ~/.bashrc
mkdir ~/local
mkdir ~/node-latest-install
cd ~/node-latest-install
curl http://nodejs.org/dist/node-latest.tar.gz | tar xz --strip-components=1
./configure --prefix=~/local
make install # ok, fine, this step probably takes more than 30 seconds...
curl https://www.npmjs.org/install.sh | sh
@thebird
thebird / PrimeEmailSignature.html
Created Nov 15, 2010
The official Prime Studios email signature
View PrimeEmailSignature.html
<table style="border-top-color: #dfdfdf; border-top-width: 1px; border-top-style: solid; width: 100%; margin-top: 10px;" border="0" cellspacing="0" cellpadding="0" align="center">
<tbody>
<tr>
<td align="left" valign="top">
<p style="margin: 0; padding: 0; font-family: Helvetica Neue, Helvetica, Arial, sans-serif; margin-top: 8px; font-weight: bold; color: #333; font-size: 12pt; line-height: 17pt;">Full Name</p>
<p style="margin: 0; padding: 0; font-family: Helvetica Neue, Helvetica, Arial, sans-serif; color: #a0a0a0; font-size: 8pt;">Prime Studios</p>
</td>
<td align="right" valign="top">
<p style="margin: 0; padding: 0; font-family: Helvetica Neue,Helvetica,Arial,sans-serif; margin-top: 8px; font-weight: bold; color: #333; font-size: 12pt; line-height: 17pt;">Phone Number</p>
<p style="margin: 0; padding: 0;"><a style="margin: 0; padding: 0; font-family: Helvetica Neue,Helvetica,Arial,sans-serif; color: #a0a0a0; font-size: 8pt; text-decoration: none;"
@rpavlik
rpavlik / fix_homebrew.rb
Created Jan 6, 2011 — forked from mxcl/install_homebrew.markdown
Fix permissions on /usr/local for Homebrew
View fix_homebrew.rb
#!/usr/bin/ruby
#
# This script fixes /usr/local only.
#
# 6th January 2010:
# Modified the script to just fix, rather than install. - rpavlik
#
# 30th March 2010:
# Added a check to make sure user is in the staff group. This was a problem
# for me, and I think it was due to me migrating my account over several
@badsyntax
badsyntax / build.sh
Created Jan 11, 2011
An example PHP & BASH Post-Receive github web hook to package projects
View build.sh
#! /usr/bin/env bash
#clone the repo
git clone -q "${1}" "clones/${2}"
cd "clones/${2}"
#update the submodules (how do we handle errors here?)
git submodule --quiet update --init --recursive
View node-and-npm-in-30-seconds.sh
echo 'export PATH=$HOME/local/bin:$PATH' >> ~/.bashrc
. ~/.bashrc
mkdir ~/local
mkdir ~/node-latest-install
cd ~/node-latest-install
curl http://nodejs.org/dist/node-latest.tar.gz | tar xz --strip-components=1
./configure --prefix=~/local
make install # ok, fine, this step probably takes more than 30 seconds...
curl http://npmjs.org/install.sh | sh
@sivel
sivel / better-cache-bust.php
Created May 13, 2011
Improve WordPress cache busting to move the version into the URL path, instead of as a query variable
View better-cache-bust.php
<?php
/*
Plugin Name: Better Cache Bust
Plugin URI: http://sivel.net/
Description: Moves the resource version in the URL path instead of as a query var
Version: 1.0
Author: Matt Martz
Author URI: http://sivel.net/
*/
@saikat
saikat / gist:1084146
Created Jul 15, 2011
Stripe sample checkout form
View gist:1084146
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="Content-type" content="text/html; charset=utf-8" />
<title>Stripe Sample Form</title>
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.6.2/jquery.min.js"></script>
<script type="text/javascript" src="https://ajax.aspnetcdn.com/ajax/jquery.validate/1.8.1/jquery.validate.min.js"></script>
<script type="text/javascript" src="https://js.stripe.com/v1/"></script>
<script type="text/javascript">
@kirkegaard
kirkegaard / sync.js
Created Jul 18, 2011
quick and dirty rsync backup script in node.js
View sync.js
#!/usr/local/bin/node
var sys = require('sys')
, fs = require('fs')
, exec = require('child_process').exec
, colors = require('colors');
var dest = '/Volumes/Drobo/BACKUP/'
, logfile = '.sync/log'
, folders = [
@treybean
treybean / deploy.rb
Created Aug 16, 2011
Heroku Deployment Script
View deploy.rb
#!/usr/bin/env ruby
# Usage
# ./deploy [staging|production] <options>
#
# Options
# -m or --maintenance - Put the application into maintenance mode
# -b or --branch - deploy from a branch other than "master"
if ['staging', 'production'].include? ARGV[0]
You can’t perform that action at this time.