The command also tells us we have not made any changes to.
Aug 10, Nothing to commit, working tree clean after calling git checkout. Ask Question Asked 3 years, 1 month ago. Active 3 years ago. Viewed 6k times By doing git checkout you went into so called"detached head" state, which in simple terms means you're not on any branch right now. If you want to return to your normal branch just do.
The problem with a detached HEAD. The HEAD pointer in Git determines your current working revision (and thereby the files that are placed in your project's working directory). Normally, when checking out a proper branch name, Git automatically moves the HEAD pointer along when you create a new commit. You are automatically on the newest commit.
nothing to commit, working directory clean. This is a good state, this is what we like to see. 2. We make a change to a file in our repository (without branching, which is what we should have done).
git status shows one modified file with changes not staged for commit.
3. Sep 21, The “nothing to commit, working directory clean” message tells us all of the changes we have made to a Git repository are committed. This means the current state of our project folder is exactly the same as that of the last commit. When you add, remove, or delete a.
Oct 23, Using git CLT to checkout a commit updates the status to HEAD detached at while doing the equivalent in libgit2 has git print a different status: Not currently on any branch. Why is this? Should this be a concern? Starting point: .