Skip to content

Instantly share code, notes, and snippets.

@davidbehan
Last active December 17, 2015 05:49
Show Gist options
  • Save davidbehan/5560561 to your computer and use it in GitHub Desktop.
Save davidbehan/5560561 to your computer and use it in GitHub Desktop.
Handy set of commands for Git
# Handy commands
git remote show origin
# Removes .DS_store from Git Repo
find . -name .DS_Store -print0 | xargs -0 git rm --ignore-unmatch
# Archive/Export
git archive master | tar -x -C /somewhere/else
git archive master | bzip2 >source-tree.tar.bz2
git archive --format zip --output /full/path/to/zipfile.zip master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment