<commit_before>---
layout: post
title: Installing Git
modified:
categories: 
description: "Installing and setting up git locally"
tags: []
image:
  feature: abstract-11.jpg
  credit:
  creditlink:
comments:
share:
date: 2016-01-04T23:32:07-08:00
---
### Installing and Setting up Git

Chances are, you already have git running on your computer or you at least have heard of Git before. For this training, you will need to setup git locally and know few basics about git.

#### Table of Contents
  - [Install Git](#install-git)
  - [Fork a Repository to your Account](#fork-the-repository-to-your-account)
  - [Clone a sample node app Repository to your Machine](#clone-the-case-study-repository-to-your-machine)
  - [Creating a new Branch for your repo](#creating-a-new-branch-for-your-repo)
  - [Staging your Changes for a Commit](#staging-your-changes-for-a-commit)
  - [Commit your Changes](#commit-your-changes)
  - [Push your new Branch to Your Fork on GitHub](#push-your-new-branch-to-your-fork-on-github)

### Installing Git
If you don't have Git installed, navigate to the official [Git Download page and download it](https://git-scm.com/download). 

#### Getting Git for Mac
There are several ways to install Git on a Mac. You can choose from one of the following ways:

1) If you want a more up to date version, you can also install it via a binary installer. An OSX Git installer is maintained and available for download at the Git website, at [http://git-scm.com/download/mac](http://git-scm.com/download/mac).

2) If you already have Homebrew, you can install Git by executing:
  
  {% highlight bash %}
  $ brew install git
  {% endhighlight %}

  Make sure you update your `$PATH` environment variable to include the latest install path of Git. For example:

  {% highlight bash %}
  $ echo 'export PATH="/usr/local/bin:/usr/local/sbin:~/bin:$PATH"' >> ~/.bash_profile
  {% endhighlight %}

3) If you don't mind registering an Apple developer account, then install the Xcode Command Line Tools. Go to [connect.apple.com](connect.apple.com) and register an Apple Developer account. Once you’ve registered, go to [developer.apple.com/xcode](developer.apple.com/xcode), then click on “View downloads” and finding the appropriate command line tools for your version of OS X in the list. When your download finishes, go ahead and open the DMG.
Run the Command Line Tools installer. On Mavericks (10.9) or above you can do this simply by trying to run git from the Terminal the very first time. If you don’t have it installed already, it will prompt you to install it. 
<commit_msg>Fix bad links in table of content<commit_after>---
layout: post
title: Installing Git
modified:
categories: 
description: "Installing and setting up git locally"
tags: []
image:
  feature: abstract-11.jpg
  credit:
  creditlink:
comments:
share:
date: 2016-01-04T23:32:07-08:00
---
### Installing and Setting up Git

Chances are, you already have git running on your computer or you at least have heard of Git before. For this training, you will need to setup git locally and know few basics about git.

#### Table of Contents
  - [Installing Git](#installing-git)
  - [Forking a Repository to your Account](#forking-the-repository-to-your-account)
  - [Cloning the Repository to your Machine](#cloning-the-repository-to-your-machine)
  - [Creating a new Branch for your repo](#creating-a-new-branch-for-your-repo)
  - [Staging your Changes for a Commit](#staging-your-changes-for-a-commit)
  - [Committing your Changes](#committing-your-changes)
  - [Pushing your new Branch to Your Fork on GitHub](#pushing-your-new-branch-to-your-fork-on-github)

### Installing Git
If you don't have Git installed, navigate to the official [Git Download page and download it](https://git-scm.com/download). 

#### Getting Git for Mac
There are several ways to install Git on a Mac. You can choose from one of the following ways:

1) If you want a more up to date version, you can also install it via a binary installer. An OSX Git installer is maintained and available for download at the Git website, at [http://git-scm.com/download/mac](http://git-scm.com/download/mac).

2) If you already have Homebrew, you can install Git by executing:
  
  {% highlight bash %}
  $ brew install git
  {% endhighlight %}

  Make sure you update your `$PATH` environment variable to include the latest install path of Git. For example:

  {% highlight bash %}
  $ echo 'export PATH="/usr/local/bin:/usr/local/sbin:~/bin:$PATH"' >> ~/.bash_profile
  {% endhighlight %}

3) If you don't mind registering an Apple developer account, then install the Xcode Command Line Tools. Go to [connect.apple.com](connect.apple.com) and register an Apple Developer account. Once you’ve registered, go to [developer.apple.com/xcode](developer.apple.com/xcode), then click on “View downloads” and finding the appropriate command line tools for your version of OS X in the list. When your download finishes, go ahead and open the DMG.
Run the Command Line Tools installer. On Mavericks (10.9) or above you can do this simply by trying to run git from the Terminal the very first time. If you don’t have it installed already, it will prompt you to install it. 

{'fraction_non_alphanumeric': 0.09679277895141156, 'fraction_numerical': 0.00998655655847897, 'mean_word_length': 4.095890410958904, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 18, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4804887', 'n_tokens_mistral': 1573, 'n_tokens_neox': 1450, 'n_words': 671}