Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EGit / JGit » Repository and project show ^nnn to represent commits not pushed, even after hard reset
Repository and project show ^nnn to represent commits not pushed, even after hard reset [message #1790768] Fri, 15 June 2018 23:32 Go to next message
David M. Karr is currently offline David M. KarrFriend
Messages: 801
Registered: July 2009
Senior Member
I work with a team that exclusively uses Eclipse egit for pushing code to our remote repository. Many of them apparently see a symptom from time to time that I have never seen, and I'm trying to understand what they might be doing differently.

For background, I note that in the repository view, or in the package/project explorer, there is info displayed on the repository or project that shows the number of commits that are different between the local repository and the remote repository. This is normal. If the local repository has 3 commits that haven't been pushed to the remote repository, I'll see "^3" in the repository or project name. Again, this is normal.

What my team members are reporting is that they will see this "^N" thing even when there appear to be no difference in the commits between the local and remote repositories. I just looked at one team member's Eclipse, and he had this symptom. It showed "^273" in the repository name. I then had him do a "hard reset" on the repository. After a few seconds to let things settle, I saw that this label didn't change. It still said "^273" in the repository name. I right-clicked on the project and selected "Compare With" and selected HEAD revision, and it showed one file in the .settings directory. This file is also the one file shown in the unstaged files in the staging view. The display never changed to remove that label.

I checked his Eclipse version, and he is using 4.7.2. I'm using 4.7.3a.
Re: Repository and project show ^nnn to represent commits not pushed, even after hard reset [message #1790782 is a reply to message #1790768] Sun, 17 June 2018 06:32 Go to previous messageGo to next message
Matthias Sohn is currently offline Matthias SohnFriend
Messages: 1268
Registered: July 2009
Senior Member
These numbers show the distance of the checked out local branch from the branch it's tracking.
In the repositories view click "Configure Branch..." on the local branch to view which branch the
selected branch is tracking. If the checked out branch does not track another branch or if you
directly checked out a commit without involving a branch this distance is undefined and hence
not displayed.

This configuration on the tracked branch is used when you run "Pull", it defines the branch to fetch from
and then to merge. The same configuration is also used to auto-populate the target branch of
the "Push Branch..." dialog.
Re: Repository and project show ^nnn to represent commits not pushed, even after hard reset [message #1790787 is a reply to message #1790782] Sun, 17 June 2018 15:47 Go to previous message
David M. Karr is currently offline David M. KarrFriend
Messages: 801
Registered: July 2009
Senior Member
The checked out branch is "master". We've already pushed changes from this local repo to the remote and verified the changes are there. The display in egit still says "^273". I can go back to him and view what "Configure Branch ..." says, but I don't believe there will be any surprises there. I didn't yet check the eclipse log, so I'll look at that when I get back to the office.
Previous Topic:Eclipse Oxygen: Git Flow is not available
Next Topic:How Can I ignore files when using ArchiveCommand
Goto Forum:
  


Current Time: Wed Apr 24 22:52:17 GMT 2024

Powered by FUDForum. Page generated in 0.02919 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top