Comparing File Versions
Introduction
IntelliJ IDEA allows you to compare the local copy of a file with its repository versions. The following options are possible:
- Compare your local copy with the repository version to which you have last synchronized
- If somebody else has committed changes since your last update compare your local copy with newest repository version
- Compare your local version with any repository version
For some version control systems, it is possible to compare a file with a branch version. The differences are displayed in the Differences viewer.
Comparing with a repository version
To compare with a repository version to which you last synchronized
- Select a file in the Project tool window, or open it in the editor.
- Do one of the following:
- From the main VCS menu, or on the context menu of a file, choose <VCS> | Compare with the same repository version.
- Select a file in the Local Changes tab of the Version Control tool window, and choose Show Diff from the context menu.
Comparing with the latest repository version
To compare with the latest repository version
- Select a file in the Project tool window, or open it in the editor.
- On the main VCS menu, or on the context menu of a file, choose <VCS> | Compare with the latest repository version.
Comparing with the specified version of a file
To compare with the specified version of a file
- Select a file in the Project tool window, or open it in the editor.
- On the main VCS menu, or on the context menu of a file, choose <VCS> | Compare with.
- In the File Revision pop-up window, click the version to compare with.
Last modified: 6 March 2018