How to view the state of a git repo using command line

64 views Asked by At

I use SourceTree mostly to work with git which lets me understand the current state of the repo easily. Given a repo which has lots of branches is it possible or easy to understand the current state of the repo using command line?

1

There are 1 answers

0
choroba On BEST ANSWER

Yes. Try

git status

to get brief information about the current status (untracked or changed files). Use

git branch -vav

to see the list of all branches with some information on them (what remote branches they track and how synchronized with them they are). Use

git log --oneline --graph --decorate --all

to see the history with branches in colours.