Notes

Git + Dropbox

# Make a new project directory
mkdir ~/project
# Change into it
cd ~/project
# Make it a git repo
git init
git add .
git commit -m "Initial commit"
# Make a directory in your Dropbox to hold git repos
mkdir ~/Dropbox/git
# Change into it
cd ~/Dropbox/git
# Make it a bare repository 
git init --bare project.git
# Change back to the project directory
cd ~/project
# Add the bare repo as a remote origin
git remote add origin ~/Dropbox/git/project.git
# Push it
git push -u origin master

Source(s)