Does git log --branches work?

前端 未结 5 976
北荒
北荒 2020-12-28 12:44

I can\'t seem to get git log --branches to correctly filter its output. It seems as if Git ignores it.

For example, the head of git log --graph --

5条回答
  •  自闭症患者
    2020-12-28 13:29

    Does anyone know how to use this command successfully?

    EDIT: All I want to be able to do is get the log of one branch or another, without having to do a checkout first.

    In order to visualise the graph of commits on all branches and remotes do this:

    $ git log --graph --branches=* --remotes=* --decorate
    

    Use this with other git-log options to control verbosity, e.g. --oneline, --name-status, etc.

    You may have to fetch remote changes first in order to see them. You can fetch all remote changes without applying them to your current branch(es) like this:

    $ git fetch --all
    

提交回复
热议问题