Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 334031

Summary: EGit 0.10.1 gets SHAs wrong on push (i.e. git status reports unpushed commits after a push using EGit UI)
Product: [Technology] EGit Reporter: Severin Gehwolf <sgehwolf>
Component: CoreAssignee: Project Inbox <egit.core-inbox>
Status: CLOSED DUPLICATE QA Contact:
Severity: normal    
Priority: P3 CC: caniszczyk, sgehwolf
Version: 0.10.0   
Target Milestone: ---   
Hardware: PC   
OS: Linux   
Whiteboard:

Description Severin Gehwolf CLA 2011-01-11 15:28:14 EST
I'm using Fedora's EGit (tag 0.10.1).

Steps to reproduce:
1. Clone a remote git repository
2. Change a file, commit
3. Push changes using Team => Push
4. Drop to a terminal and run $ git status
5. Git status reports uncommitted changes
6. $ git push origin master (reports Everything up-to-date).

It appears that the push actually happens. However, .git/refs/remotes/origin/master is not updated to point to the latest SHA.

Suppose the following example:

$ git log --format=oneline -n2
723021cf6d4cb1232fecea0d8cef59d02cfdccde EGit push test (yet again).
8e1f0aa217f60c840de80ad89c5ca5b1c81d498c EGit push test. 

723021cf6d4cb1232fecea0d8cef59d02cfdccde is the only unpushed commit.

After a EGit push:

$ find . -mmin -5
./.git
./.git/config
./.git/refs/heads/master
./.git/index
$ cat ./.git/refs/remotes/origin/master
8e1f0aa217f60c840de80ad89c5ca5b1c81d498c

After a $ git push origin master

$ find . -mmin -5
./.git
./.git/config
./.git/refs/remotes/origin/master
./.git/refs/heads/master
./.git/index
$ cat ./.git/refs/remotes/origin/master
723021cf6d4cb1232fecea0d8cef59d02cfdccde

What's more, EGit's "Push origin" dialog showing up after the push reports the "old" SHA. I.e. 8e1f0aa217f60c840de80ad89c5ca5b1c81d498c in the above example.
Comment 1 Chris Aniszczyk CLA 2011-01-12 10:02:29 EST
This is a dupe of bug 317411.

*** This bug has been marked as a duplicate of bug 317411 ***