Skip to main content

Git Push StudioFrom your first commit to advanced workflows.

A free, practical Git command reference for developers. 28 commands across 8 categories — from git init to git rebase.

bashgit log --oneline --graph
$ git log --oneline --graph --all
* 1a2b3c4HEAD -> mainfeat: interactive command palette search
| * 5d6e7f8feature/dark-moderefactor: refine design tokens
| * 9a0b1c2fix: remove layout shift on theme change
|/
* 3d4e5f6Merge branch 'feature/command-reference'
* 7g8h9i0Initial commit — 28 commands and examples
Commands
28 · across 8 categories
Examples
Copy & run · verified output
Cost
Free · no sign-up
Platform
Any · static, offline-ready
Static by design — no account, no tracking UI, works offline.
Command index

Every command, organised by the task you are doing

From first-day setup to history rewriting. Each category lists the commands it covers so you can jump straight to the one you need.

Getting Started

04 cmds

Initialize repositories, clone remote code, set credentials, and navigate the help manuals.

  • git init
  • git clone
  • git config
  • git help

Working with Changes

04 cmds

Check working directory status, stage files, record snapshots, and review diffs.

  • git status
  • git add
  • git commit
  • git diff

Branching & Merging

04 cmds

Isolate feature work, switch branches, integrate changes, and rebase cleanly.

  • git branch
  • git checkout
  • git switch
  • git merge

Inspecting History

05 cmds

Filter commits, format graph logs, trace line changes, and audit with blame.

  • git log
  • git show
  • git blame
  • git reflog
  • git shortlog

Remote Repositories

04 cmds

Configure remotes, push commits, pull upstream changes, and inspect remote refs.

  • git remote
  • git push
  • git pull
  • git fetch

Stashing & Cleaning

02 cmds

Shelve uncommitted work temporarily, inspect stash stacks, and clear artifacts.

  • git stash
  • git clean

Tagging & Releases

02 cmds

Create lightweight and annotated release tags, inspect signatures, describe versions.

  • git tag
  • git describe

Undoing Changes

03 cmds

Discard local edits, step commit pointers back, or create non-destructive reverts.

  • git restore
  • git reset
  • git revert
Core topics

What you can learn here

Mental models, real terminal transcripts and copyable commands — written to help you write, branch and ship with confidence.

The command reference

The core resource covers 28 Git commands organised into 8 categories. Every entry explains the underlying mechanics, the flags that matter, and tested copyable terminal examples.

Ctrl + K to searchOpen the reference

The core Git workflow

Most daily development comes down to four commands: git init, git add, git commit and git push. Learn the order and the reasoning behind each step.

Branching & collaboration

Create and switch branches, merge cleanly, decide when to rebase versus merge, and resolve conflicts calmly. Works with GitHub, GitLab and Bitbucket.

In-depth tutorials

Longer articles cover bisecting bugs with git bisect, semantic commit messages, automated hooks, worktrees, and recovering a detached head.

Learn by doing

Reading is not enough. Run every snippet in a throwaway repository and build real muscle memory — git reflog has you covered when something goes wrong.

Troubleshooting

Answers to the panic moments: undoing committed secrets, rewriting old commit messages, and restoring accidentally deleted local branches.

Quick start

Your first five minutes with Git

Install Git, configure your identity, and take your first snapshot. Then read the full reference whenever a command gets in your way.

Step 1 — Configure identity

# Set your global author signature
git config --global user.name "Your Name"
git config --global user.email "you@example.com"

Step 2 — Initialize & commit

# Create the repo and save your first snapshot
git init my-project && cd my-project
git add . && git commit -m "Initial commit"
How it works

Four steps from a command name to a working change

No gatekeeping and no filler. Read the reference, check the output, then run the command in a real repository.

  1. 01

    Pick a command

    Browse 28 commands across 8 categories — from init and commit through to interactive rebase and reflog recovery.

  2. 02

    Understand the mechanics

    Each entry explains what Git actually does, the flags that matter, and the state it leaves your repository in.

  3. 03

    Read the real output

    Examples are complete and copyable, with the terminal output shown so you know what to expect before you run it.

  4. 04

    Run it yourself

    Practise in a scratch repository. Build the muscle memory once, then reuse it on real work.

Verified examples

Every command page ships with a runnable transcript

No guessing which flags to pass or what the terminal should print. Learn the rationale, see the options, and copy the command straight into your shell.

Browse all 28 commands
bashdaily-workflow.sh
# 1. Check current repository status
$ git status -s
# 2. Stage with intent, commit with clarity
$ git commit -m "feat(auth): session validation"
# 3. Create a clean isolated branch
$ git switch -c feature/v2-dashboard
# 4. View a concise history graph
$ git log --oneline --graph -n 3
Support

Frequently asked questions

Clear answers about Git commands, daily workflows, resolving merge conflicts, and undoing mistakes.

Still stuck on a command or an edge case?

The Git Field Guide · 97 pages

The Git Field Guide

Master Git offline with a complete, structured course in PDF + ePub. One-time payment, free updates forever.

  • DRM-free PDF and ePub
  • Real terminal transcripts with output
  • Safe rebase and recovery drills
  • Instant download, lifetime updates
Get the Guide — ₹499Instant download · Secure checkout
pdfgit-field-guide.pdf
# Table of contents
01. The Git Mental Model
p. 06
02. Commit & Staging Architecture
p. 22
03. Conflict-Free Branch Merges
p. 41
04. Safe Interactive Rebasing
p. 63
05. Emergency Recovery with Reflog
p. 84
PDF + ePub₹499 one-time
Freelance engineering

Available for project work and long-term retainers

I work with small product teams that need senior engineering judgement without a full-time hire.

CI/CD Pipelines
GitHub Actions, GitLab CI and deployment pipelines that fail fast and read clearly.
Cloud Infrastructure
AWS, GCP and Azure setup, networking, IAM and cost control that survives an audit.
Code Quality
Reviews, testing strategy, refactoring and dead-code removal before it becomes debt.
Monitoring & Reliability
Structured logging, metrics, alerting and incident runbooks your team will actually use.
Git Training & Workshops
Hands-on sessions for teams stuck on branching strategy, rebases and merge conflicts.
Performance Tuning
Build times, database queries and runtime latency profiled, then fixed at the source.

Have a project in mind?

Tell me the scope, deadline and constraints. I reply within one business day.

Start a conversation