Skip to content

Instantly share code, notes, and snippets.

@olalonde
olalonde / docker-machine-use-nfs.sh
Created August 13, 2015 14:48
Use NFS instead of vboxsf in Docker Machine
#!/bin/bash
#
# This script will mount /Users in the boot2docker VM using NFS (instead of the
# default vboxsf). It's probably not a good idea to run it while there are
# Docker containers running in boot2docker.
#
# Usage: sudo ./boot2docker-use-nfs.sh
#
@haggen
haggen / README.md
Last active September 11, 2018 03:19
boot2docker on nfs

Get boot2docker working with nfs instead of vboxsf.

Tested on:

- Boot2Docker-cli version: v1.6.0
  Git commit: 9894ae9
- Boot2Docker-cli version: v1.6.2
  Git commit: cb2c3bc
@philss
philss / git_utils.sh
Last active August 29, 2015 14:14
A collection of shell script functions to work with git.
# Returns a list of files with a given term
function git_grep_files() {
git grep $1 | awk -F ':' '{print $1}' | sort | uniq
}
# Replace terms inside a git repository
#
# Example:
# git_replace "original_term" "new_term"
function git_replace() {
@rafaelrinaldi
rafaelrinaldi / yosemite.md
Last active January 28, 2017 16:39
Steps to configure my local Ruby env after upgrading to Yosemite
  1. Update Xcode command line tools (it should take a while)
$ xcode-select --install
  1. Update (Homebrew and) PhantomJS
$ brew update && brew upgrade phantomjs
@webinfinita
webinfinita / bootstrap-breakpoints.sass
Last active February 27, 2024 17:23
Variables for responsive design in bootstrap with sass
@mixin breakpoint($point)
@if $point == lg
@media (min-width: 1200px)
@content
@else if $point == md
@media (min-width: 992px) and (max-width: 1199px)
@content
@else if $point == sm
@nabucosound
nabucosound / heroku_env_copy.sh
Created December 30, 2013 12:40
Script to copy environment variables from an existing heroku app to another one
#!/bin/bash
# Source: http://blog.nonuby.com/blog/2012/07/05/copying-env-vars-from-one-heroku-app-to-another/
set -e
sourceApp="$1"
targetApp="$2"
while read key value; do
@ryanb
ryanb / chef_solo_bootstrap.sh
Created April 5, 2012 04:35
Bootstrap Chef Solo
#!/usr/bin/env bash
apt-get -y update
apt-get -y install build-essential zlib1g-dev libssl-dev libreadline5-dev libyaml-dev
cd /tmp
wget ftp://ftp.ruby-lang.org/pub/ruby/1.9/ruby-1.9.3-p125.tar.gz
tar -xvzf ruby-1.9.3-p125.tar.gz
cd ruby-1.9.3-p125/
./configure --prefix=/usr/local
make
make install
@coreyhaines
coreyhaines / .rspec
Last active August 15, 2024 15:13
Active Record Spec Helper - Loading just active record
--colour
-I app
@jimbojsb
jimbojsb / gist:1630790
Created January 18, 2012 03:52
Code highlighting for Keynote presentations

Step 0:

Get Homebrew installed on your mac if you don't already have it

Step 1:

Install highlight. "brew install highlight". (This brings down Lua and Boost as well)

Step 2: