来自eclipse的部分git提交(egit)

Partial git commit from eclipse (egit)

假设我有一个文件有两个更改。如何使用egit只提交其中一个?

在这个问题中可以找到命令行版本。


您还可以遵循"Eclipse中的git部分分段"

From the staging view, double-click on the file. A compare dialog will appear.

  • On the left are your current changes;
  • on the right is the currently staged work.

You can now copy changes from the left to the right, effectively staging parts of your file. In this case I will stage the correction to the method name.

http://eclipsesource.com/blogs/wp-content/uploads/2014/06/Screen-Shot-2014-06-02-at-11.11.26-PM.png