Git History

EGit leverages the Eclipse History view to help you explore the version history of a Git repository.

The History View

To open the History view, select a Git-managed project in the Project Explorer and use the context menu command Team → Show in History.

History View

The History view consists of three main sections:

History View

To investigate a specific commit, select it in the version history and view the details using the File List and Commit Details sections.

To examine changes for a particular file in the selected commit, use the Compare commands in the context menu.

Compare Options

Compare Dialog

- **File-by-file compare:** Compares only the selected file.
- **Logical model compare:** Compares all files within the same logical model (e.g., one .emx file and zero to many .efx files).
- **Closure compare (all workspace):** Compares all files in the workspace.

For more information on comparison types, refer to the document Comparing and Merging Models.

Filtering the History View

The Git History view offers several tools for filtering commit history, allowing you to focus on specific changes or navigate through the repository more effectively.

History View

Searching the History View

The search features in the Git History view allow you to explore the commit history more deeply and customize how the history is displayed. History View

Comparing from History View – Git Tree Compare View

If you select two commits in the History view, you can use the "Compare with Each Other in Tree" command from the context menu.

Compare in Tree

This opens the Git Tree Compare View, showing differences between the selected commits in terms of added, removed, or modified files or directories.

To initiate a file comparison, click the "Compare mode" button in the toolbar:

Compare Mode Button

Then, double-click a file to start a file-by-file comparison.

If you select only one commit and use the "Compare with Workspace" command, the Git Tree Compare View will show differences between the selected commit and your current workspace.

Compare with Workspace

In this case, double-clicking a file opens the "Select kind of compare" dialog, allowing you to expand the comparison to a logical model or closure compare.

Using the Git Repositories View to Investigate Branches

For a simple overview of available branches, the Git Repositories view is a useful alternative to the History view. It provides a concise summary of the branches in the repository and highlights the currently checked-out branch.

To open the Git Repositories view, right-click a Git-managed project in the Project Explorer and select Team → Show in Repositories View.

To view your local branches, expand Branches → Local.

Local Branches

The currently checked-out branch is marked with a checkbox and is also displayed in brackets after the project name in both this view and the Project Explorer.