Skip to content

Instantly share code, notes, and snippets.

git branch -m old_branch new_branch # Rename branch locally
git push origin :old_branch # Delete the old branch
git push --set-upstream origin new_branch # Push the new branch, set local branch to track the new remote
#!/bin/bash
# vim:set ts=4 sw=4 et ai:
# Retrieve SSH public keys from GitHub and install to authorized_keys.
GITHUB_USERS=(USER1 USER2)
INSTALL_FILE=/home/USER/.ssh/authorized_keys
TMP_KEY=/tmp/ssh.key
CURL=/usr/bin/curl
CURLOPTS="--retry 3 --retry-delay 2 --silent --fail -o $TMP_KEY"

Launch Sublime Text 2 from the Mac OS X Terminal

Sublime Text 2 ships with a CLI called subl (why not "sublime", go figure). This utility is hidden in the following folder (assuming you installed Sublime in /Applications like normal folk. If this following line opens Sublime Text for you, then bingo, you're ready.

open /Applications/Sublime\ Text\ 2.app/Contents/SharedSupport/bin/subl

You can find more (official) details about subl here: http://www.sublimetext.com/docs/2/osx_command_line.html

Installation

tmux cheatsheet

As configured in my dotfiles.

start new:

tmux

start new with session name:

Sublime Text 2 – Useful Shortcuts (Mac OS X)

OS X Keys

command
option
control
shift

General