Вопрос

I have a branch in git and I am on that branch and not on master branch.
Using git log --graph I can only see linearly that I am on that branch. But I can not see that I have "splitted" from the master branch.
I.e. I see:

* b  
*     
*    
*    

Where b is the private branch I made and I was expecting to see:

*master  
* / *b  
*    
*  
*  

But I do see this in gitk. Is it not possible to get an accurate graph of the tree via command line?

Это было полезно?

Решение

In order to see the same as in gitk, you would need at least a:

git log --branches

A more complete equivalent would be a:

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

I use a more complex alias in "How to display the tag name and branch name using git log --graph".

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top