Status
Published Nov 4, 2021Updated Mar 5, 2022
Contribute to Docs
In Git, the status
command shows the state of the working directory, staging area, and which files are untracked (names shown in red and not staged) or tracked (shown in green and staged). The tracked files, shown in green, are found in the staging area and will be saved with the next commit.
Example
Below is a short example of how the git status
command works. Assuming a change was saved in a text file, example.txt, running git status
will show that:
$ git statusOn branch mainNo commits yetUntracked files:(use "git add <file>..." to include in what will be committed)example.txtnothing added to commit but untracked files present (use "git add" to track)
All contributors
- Anonymous contributorAnonymous contributor11 contributions
- Anonymous contributorAnonymous contributor3077 contributions
- Pandz18
- Anonymous contributor
- Anonymous contributor
Looking to contribute?
- Learn more about how to get involved.
- Edit this page on GitHub to fix an error or make an improvement.
- Submit feedback to let us know how we can improve Docs.