Viewing unpushed Git commits

前端 未结 25 2819
Happy的楠姐
Happy的楠姐 2020-11-22 08:05

How can I view any local commits I\'ve made, that haven\'t yet been pushed to the remote repository? Occasionally, git status will print out that my branch is X

25条回答
  •  滥情空心
    2020-11-22 09:04

    You can show all commits that you have locally but not upstream with

    git log @{u}..
    

    @{u} or @{upstream} means the upstream branch of the current branch (see git rev-parse --help or git help revisions for details).

提交回复
热议问题