> ## Content Index
> Fetch the complete content index at: https://hitechhobby.com/llms.txt
> Use this file to discover other available public pages before exploring further.

# Git the Basics
- URL: https://hitechhobby.com/git-the-basics/
- Published: 2017-11-18T18:59:39.000Z
- Updated: 2026-10-20T04:43:27.000Z
- Description: Git is a fantastic tool, and the industry standard for source control (Sorry SVN users, but its better). Here you'll Learn Git in 10 steps or less!
- Author: HitechHobby
- Tags: Guides, #wp, #wp-post, #Import 2026-10-20 04:41

Git is a fantastic tool, and the industry standard for source control (Sorry SVN users, but its better). Learning Git in its entirety, can be somewhat daunting, but here we’ll highlight the main things you need to get started and some tools we like, to help you learn.

## 1\. Git Clone

The `git clone` command is used to copy source code from the **remote** repository (“repo”) to your **local** device. This is the first command you will use when working with an existing Git project locally. [Docs Here.](https://git-scm.com/docs/git-clone?ref=hitechhobby.com)

## 2\. Git Status

The `git status` command is a helpful tool for viewing the status of your ***local*** copy of the source. It will tell you which branch you are using and any changes to the code. [Docs Here.](https://git-scm.com/docs/git-status?ref=hitechhobby.com)

## 3\. Git Checkout

The `git checkout` command is used to switch between different branches in the repository. Common branches include `master` and `develop`, but may also include `features` branches as we’ll see later. Example: `git checkout master` will check out the `master` branch **locally**. [Docs Here.](https://git-scm.com/docs/git-checkout?ref=hitechhobby.com)

## 4\. Git Pull

The `git pull` command will update your ***local*** copy of the source, from the **remote** source, for the branch you currently have checked out. [Docs Here.](https://git-scm.com/docs/git-pull?ref=hitechhobby.com)

## 5\. Git Stash

The `git stash` command will revert and store any changes you have made to your ***local*** code (but have not committed); allowing you to restore them later with `git stash pop`. This command is useful if you run into issues when pulling your code. [Docs Here.](https://git-scm.com/docs/git-stash?ref=hitechhobby.com)

## 6\. Git Add/Remove

The `git add` and `git rm` commands are used to tag files changed ***locally***, to be sent to the **remote** source, on the next commit of the branch you have checked out. [Add Docs Here.](https://git-scm.com/docs/git-add?ref=hitechhobby.com) [Remove Docs Here.](https://git-scm.com/docs/git-rm?ref=hitechhobby.com)

## 7\. Git Commit

The `git commit` command stages changes added ***locally***, to be sent to the **remote** source. A commit can contain a message about the work done in these code changes. Example: `git commit -m "Added Awesome New Feature!"` will group together all the ***local*** changes you have made to your project, in all the files you have added. This group of changes will be sent to the **remote** server on the next push. [Docs Here.](https://git-scm.com/docs/git-commit?ref=hitechhobby.com)

## 8\. Git Push

The `git push` command completes the process of sending your changes to the server. You will now be able to see these changes in the web interface, and others will be able to pull your changes. [Docs Here.](https://git-scm.com/docs/git-push?ref=hitechhobby.com)

# Extra Credit: git-flow

Git-flow is a powerful tool that can help you organize new branches and follow a hierarchical work-flow for your code. Git-flow creates the branches `master`, `develop`, and `features` and handle much of the branching merging process. You’ll need to follow these instructions to install git-flow [https://github.com/nvie/gitflow/wiki/Installation](https://github.com/nvie/gitflow/wiki/Installation?ref=hitechhobby.com)

## 9\. Git-flow Init

The `git-flow init` command will initialize your **local** project with the appropriate branches and settings. Its fine to just use the defaults provided by the command. When finished, you can checkout and push each of the created branches to send them to the **remote** repo. [Docs Here.](https://github.com/nvie/gitflow?ref=hitechhobby.com)

## 10\. Git-flow Feature

The `git-flow feature` command sets up a new branch for you, inherited from the `develop` branch and organized with the `feature/` prefix. Example: `git-flow feature start awesome_new_feature` will create a new local branch called `feature/awesome_new_feature` that when finished, can be merged back into `develop` with `git-flow feature finish awesome_new_feature`. [Docs Here.](https://github.com/nvie/gitflow?ref=hitechhobby.com)

Now Lets look at the whole process:

1. Clone and Initialize

[![](https://hitechhobby.com/content/images/hitechhobby-com/wp-content/uploads/2017/11/clone-300x209.png)](https://hitechhobby.com/content/images/hitechhobby-com/wp-content/uploads/2017/11/clone.png)

2\. Change and Commit

[![](https://hitechhobby.com/content/images/hitechhobby-com/wp-content/uploads/2017/11/comit-300x208.png)](https://hitechhobby.com/content/images/hitechhobby-com/wp-content/uploads/2017/11/comit.png)

3\. Push

[![](https://hitechhobby.com/content/images/hitechhobby-com/wp-content/uploads/2017/11/push-300x208.png)](https://hitechhobby.com/content/images/hitechhobby-com/wp-content/uploads/2017/11/push.png)

As we said before, git is very powerful and this is just the tip of the iceberg. Please follow the included links about each feature if you need more detail on how they are used.

[git-flow cheatsheet](https://danielkummer.github.io/git-flow-cheatsheet/?ref=hitechhobby.com)