Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/elixir/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Git 如何判断合并中包含哪些提交?_Git_Merge - Fatal编程技术网

Git 如何判断合并中包含哪些提交?

Git 如何判断合并中包含哪些提交?,git,merge,Git,Merge,我使用以下命令将branch develop合并到branch my功能中: $ git merge --no-ff develop 我预计之后,我的功能分支将领先于origin/my功能两次提交:合并提交和我想要引入的另一次提交。但是,git status报告说它领先三次提交: $ git status On branch my-feature Your branch is ahead of 'origin/my-feature' by 3 commits. (use "git push

我使用以下命令将branch develop合并到branch my功能中:

$ git merge --no-ff develop
我预计之后,我的功能分支将领先于origin/my功能两次提交:合并提交和我想要引入的另一次提交。但是,
git status
报告说它领先三次提交:

$ git status
On branch my-feature
Your branch is ahead of 'origin/my-feature' by 3 commits.
  (use "git push" to publish your local commits)
nothing to commit, working directory clean
我想在不梳理日志的情况下找出合并中包括哪些提交。是否有命令列出它们或只是列出“前面”的提交?我尝试了一次硬重置,并使用了git merge--log,以为它会在日志消息中列出它们,但它只显示了一次提交。

您可以使用

git log origin/my-feature..my-feature
查看分支中尚未推送的提交(前一个提交)

由于您已经使用了
my feature
,您可以将其缩短为:

git log origin/my-feature..