Skip to content

Instantly share code, notes, and snippets.

@roolo
roolo / mysql2-gem-install.sh
Last active December 25, 2018 07:43
Fixing "Incorrect MySQL client library version! This gem was compiled for 5.5.29 but the client library is 5.6.10. (RuntimeError)" on OS X while using Brew
ARCHFLAGS="-arch x86_64" gem install mysql2 -- –with-mysql-config=/usr/local/bin/mysql_config
@trey
trey / happy_git_on_osx.md
Last active October 9, 2025 17:52
Creating a Happy Git Environment on OS X

Creating a Happy Git Environment on OS X

Step 1: Install Git

brew install git bash-completion

Configure things:

git config --global user.name "Your Name"

git config --global user.email "you@example.com"

@CristinaSolana
CristinaSolana / gist:1885435
Created February 22, 2012 14:56
Keeping a fork up to date

1. Clone your fork:

git clone git@github.com:YOUR-USERNAME/YOUR-FORKED-REPO.git

2. Add remote from original repository in your forked repository:

cd into/cloned/fork-repo
git remote add upstream git://github.com/ORIGINAL-DEV-USERNAME/REPO-YOU-FORKED-FROM.git
git fetch upstream
@RobertAudi
RobertAudi / please.rb
Created December 2, 2010 12:50
`pmset schedule` wrapper to easily schedule OS X to sleep, shutdown, etc
#!/usr/bin/env ruby
# NOTES:
# - This script only works on OS X.
# - This script was only tested with ruby 1.9.2 using
# the aaronh-chronic gem. If the chronic gem is used
# instead, this script will not work (unless the chronic
# gem was updated to work with ruby 1.9.2).
require 'rubygems'