简体   繁体   English

如何在EGit中查看eclipse中单个分支的历史记录

[英]How can I view the history of a single branch in EGit for eclipse

When reviewing code in eclipse using EGit plugin, before merging it to the develop branch, you switch to the branch and see what files changed with the commits on that branch. 在使用EGit插件查看eclipse中的代码时,在将其合并到develop分支之前,切换到分支并查看哪些文件随该分支上的提交而更改。 For this I would like to see -only- the commits to the current checked out branch. 为此我想看 - 只是 - 当前签出分支的提交。 When using Team -> Show in History, I get the complete history across all branches. 使用Team - > Show in History时,我可以获得所有分支的完整历史记录。

How can I view only the commits to the current checked out branch, instead of having to search trough the complete GIT history to find the relevant commits? 如何仅查看当前签出分支的提交,而不必通过完整的GIT历史记录搜索以查找相关提交?

Using review tools like Gerrit are not an option. 使用像Gerrit这样的评论工具不是一种选择。

You can check the filter button in the History View : 您可以在历史记录视图中查看过滤器按钮:

All Branches 所有分支机构

http://wiki.eclipse.org/images/3/3b/Egit-0.9-history-view-allbranches.png

This toggle activates the " All Branches " mode. 此切换激活“ All Branches ”模式。
By default, only those commits are shown in the commit log that can be reached from the currently checked out commit, ie the Commit Graph ends with the currently checked out commit and newer commits are not shown. 默认情况下,只有那些提交在提交日志中显示,可以从当前检出的提交到达,即提交图以当前检出的提交结束,并且不显示更新的提交。
If this button is down, all commits will be shown in the commit log. 如果此按钮关闭,则所有提交都将显示在提交日志中。
This is illustrated in the following picture from our example. 这在我们的示例的下图中说明。 The branch "beforeSplit" is currently checked out; 目前已检出“beforeSplit”分支; by activating the toggle, the newer branches will become visible: 通过激活切换,较新的分支将变为可见:

http://wiki.eclipse.org/images/c/c7/Egit-0.9-history-view-allbranchesToggle.png

And you need to combine that with: 你需要将它与:

"Additional Refs" toggles the visibility of certain Refs created during actions like fetch, rebase, merge, for example FETCH_HEAD, ORIGIN_HEAD... This can be helpful to remove clutter from the history view. “Additional Refs”切换在fetch,rebase,merge等操作期间创建的某些Refs的可见性,例如FETCH_HEAD,ORIGIN_HEAD ......这有助于从历史记录视图中删除混乱。

http://wiki.eclipse.org/images/0/0e/Egit-3.1-HistoryViewSettings.png

取消选中“附加参考”

You might need to un-check the "Additional Ref" option. 您可能需要取消选中“其他参考”选项。 please see the attached image. 请参阅附图。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM