threads / discuss / 15893

EGIT compare editor

Subject: EGIT compare editor

## tl;dr

3 messages between Oct 14, 2008 and Mar 8, 2011.

replies: 2people: 3as markdown or json

Chris Dumoulin· Oct 14, 2008, 14:18 UTC · lore

I seem to have successfully installed EGIT in Eclipse 3.4.1, but I can't figure out how to bring up the compare editor to view diffs.

The EGIT plugin seems to be loaded and working for my project; I see "[Git @ master]" beside the project name, and ">" beside changed files. Also, the quickdiff seems to be working; I see a different colour in the left margin beside changes within the file. The "Team" context menu seems to be populated properly: "Commit", "Update Index (Refresh)", "Show in Resource History", "Assume unchanged", "Track (Add)", "Untrack (Remove)", "Apply Patch...", and below the separator "Show Local History".

I expect that after right-clicking on a changed file, I would have some option under "Compare With" or "Team" that would allow me to diff the current file against the HEAD or some other revision using the compare editor, but I can't seem to find any way to do this. How do I bring up the compare editor to view diffs?

Thanks, Chris

Shawn O. Pearce· Oct 14, 2008, 15:05 UTC · re: Chris Dumoulin · lore

Re: EGIT compare editor

Chris Dumoulin <dumoulin@oanda.com> wrote:
Show 8 quoted lines
> I seem to have successfully installed EGIT in Eclipse 3.4.1, but I can't  
> figure out how to bring up the compare editor to view diffs.
>
> I expect that after right-clicking on a changed file, I would have some  
> option under "Compare With" or "Team" that would allow me to diff the  
> current file against the HEAD or some other revision using the compare  
> editor, but I can't seem to find any way to do this. How do I bring up  
> the compare editor to view diffs?

Robin knows the Eclipse integration better than I, but we may be missing the feature to compare the working directory revision to the last committed revision (or the index revision).

I'm pretty sure the compare editor is available in the History view (Team -> Show resource in History) by double clicking the file path when a commit node is selected. But that's obviously only historical diffs.

-- 
Shawn.
chrismarx· Mar 8, 2011, 21:01 UTC · re: Shawn O. Pearce · lore

Re: EGIT compare editor

This thread is really high in google searches, and threw me off when I first started using git. I think most people who are finding this thread are probably wanting to know how to compare files with egit, or why they can't see the compare functionality at all.

If you're using egit, and your project is setup properly in eclipse, then you should be able to just right-click and compare-with (head, etc). If you don't see this option, perhaps you're project isn't actually being managed by egit. check that the project name has something like [yourproject master/branch] attached the tittle, and that under "Team" (right click on project) you're seeing git options/commands. If not, try team-share and hook up your project to the right repository.

Official reference guide is here - http://help.eclipse.org/helios/index.jsp?topic=/org.eclipse.egit.doc/help/EGit/User_Guide/Inspecting-the-state-of-the-Repository.html

-- View this message in context: http://git.661346.n2.nabble.com/EGIT-compare-editor-tp1332809p6142419.html Sent from the git mailing list archive at Nabble.com.

← back to recent threads