Skip to content

Instantly share code, notes, and snippets.

@benders
Last active July 27, 2016 09:51
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save benders/5323144 to your computer and use it in GitHub Desktop.
Save benders/5323144 to your computer and use it in GitHub Desktop.
New Employee git setup
FULLNAME=`finger "$USER" | awk -F: '{ print $3 }' | head -n1 | sed 's/^ //'`
# Git needs to know who you are!
git config --global user.name "${FULLNAME}"
git config --global user.email "${USER}@newrelic.com"
# SVN style shortcuts
git config --global alias.st status
git config --global alias.ci commit
git config --global alias.co checkout
git config --global alias.br branch
# Colorize most things
git config --global color.branch auto
git config --global color.diff auto
git config --global color.interactive auto
git config --global color.status auto
# Only push current branch, setup remote branches to rebase on pull
git config --global push.default nothing
git config --global branch.autosetuprebase always
# Globally ignore some MacOS cruft
echo ".DS_Store" >> ~/.gitignore
git config --global core.excludesfile ~/.gitignore
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment