Installing Git

Git is an open-source version control system, and helps tremendously with collaborative project development.

The Sponge project, alongside thousands of other open-source projects, hosts its Git repositories on GitHub. Thus, Git is a crucial tool in the development of Sponge and the Sponge API.

The Git website has substantial documentation, and their downloads page offers a range of options for GUI clients suitable for various operating systems.

Plunder

Ye’ Ol’ Portholes

GitHub Desktop is an easy method of installing Git on Windows, because Git is included as a part of the software.

Rebooting your computer after installing Git is recommended.

Mac

There are a couple of ways to install Git on macOS.

The easiest method is to install Xcode Command Line Tools.

Warning

These instructions do not work on Macs running a version older than Mavericks. If you are running a version of OS X older than Mavericks, install the GitHub client instead.

  1. Launch the Terminal.

  2. Run xcode-select --install.

  3. Install it, and grab a cookie while you wait.

  4. Run git from the Terminal.

Alternatively, you can install GitHub Desktop. Git is available as a part of the GitHub Desktop installation.

Rebooting your computer after installing Git is recommended.

Linux and Unix

The simplest method of installing Git on Linux is by using the package manager that came with your Linux distribution.

Note

You may need to prefix these commands with sudo.

  1. Launch the Terminal.

  2. Run apt-get install git if you are on a Ubuntu or Debian-based distribution. Run yum install git if you are on Fedora.

GitHub Desktop is currently not available for Linux, unlike Windows and Mac.

Rebooting your computer after installing Git is recommended.

Setup

Who Are You?

Before you even start to work with git and the repository, make sure your git configuration has your identity set up. Open up your CLI and enter:

git config --list

Look for user.name and user.email. If they are not the same username and email as your GitHub account then set them:

git config --global user.name "John Doe"
git config --global user.email [email protected]

Tip

Do not proceed with any contribution in any Sponge repository until you establish your user.name and user.email.