Fork me on GitHub

Set up Git from the command line:

  • detailed instructions are on CodeRefinery

  • basic setup (if you copy-paste the commands below, omit the ‘$’ symbol):

$ git config --global user.name "Your Name"
$ git config --global user.email yourname@example.com
$ git config --global core.editor your-editor

your-editor: vim, emacs, nano, any other of your choice (if you work on Windows, please check these instructions)

  • to verify your setup from the command line run git config VARIABLE; for instance to check what is the current user.name used by Git run:
$ git config user.name
  • all current Git settings can be listed with:
$ git config --list
  • to see where this Git setup is stored:
$ git config --list --show-origin
  • if you want to set up Git locally (for a particular repository), omit the --global argument in git config commands above

  • useful Git aliases, which we use in Git workshops:

$ git config --global alias.graph "log --all --graph --decorate --oneline

Create GitHub account

  • create an account on GitHub
  • to connect to Github without the need to type your login and password each time, set up your SSH keys by following the steps described in this tutorial