7 Lesser Known Git Commands to Save You Time

Paul Hayman
4 min readJun 15, 2023

Git, the popular version control system, offers a wide range of commands that can greatly improve your productivity as a developer. While most developers are familiar with the basic Git commands, there are several lesser-known commands that can save you valuable time and effort.

In this article, we will explore seven such commands that will enhance your Git workflow and help you become a more efficient developer.

Note: Remember to replace <commit>, <branch>, and <archive_name> with the appropriate commit hash, branch name, or desired archive name in the examples.

git stash

Have you ever found yourself in a situation where you need to switch to a different branch, but you have uncommitted changes in your current branch? The git stash command comes to the rescue. It allows you to temporarily save your changes without committing them. This command stashes away your modifications, allowing you to switch branches or perform other tasks, and then later retrieve the changes when you're ready to continue working on them.

 git stash

This command saves your current changes in a temporary stash, allowing you to switch branches or perform other tasks. You can later apply the stashed changes using git stash apply or git stash pop.

--

--

Paul Hayman

Co-Founder at K3YS (alaska.games), COO of KWIBOO & Technical Director at PrivateDoc