Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

'git pull' request are not working for repo in stash 1.2

Tim Goeke October 24, 2012

We have four developers working in stash 1.2. Two of the developers are about 7 commits behind the current git head. When I do a "git pull", I expect that those 7 commits will get pulled, but in fact nothing happens.

Performing a new clone on the repo results in all the commits to be pulled, as expected.

The other two developers have not had this issue, ie they were able to pull the commits without errors. As I mentioned previously, the workaround is to do a new "git clone".

Summary

Doing a "git pull" shows "Already up-to-date." which is wrong.

4 answers

0 votes
Tim Goeke October 25, 2012

We had already run fetch with no effect. I talked with the affected devs and they have already cloned new repos, so we'll have to wait until it happens again to try more diagnostics.

0 votes
Stefan Saasen
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
October 25, 2012

Hi Tim,

Could you please run:

git fetch -v
git branch -r -v

Fetch will retrieve all the changes, `git branch -r -v` will show you the remote branches you track in your local repository including the commit they point to.

This list should match the latest changes that are on the Stash server.

If this list of commits is correct then your local branches need to be updated to reflect those changes, but retrieving the changes actually worked.

Let me know if you see the latest changes on the remote tracking branches.

Cheers,

Stefan

0 votes
Tim Goeke October 25, 2012

Yes, I tried 'git fetch' as well, with the same result.

jhinch (Atlassian)
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
October 25, 2012

The important step is the git merge. git fetch only updates the remote branches. I would suggest getting in contact with support

0 votes
jhinch (Atlassian)
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
October 25, 2012

git pull is just a shortcut for a git fetch followed by a git merge of the checkout branch with its remotely tracked branch. This may be occurring if there are difference in the branches which are currently checked out by different developers or if they have different remotely tracked branches.

Lets say you want to make sure you have the latest master from the remote repository. You first check you are on master:

git branch

Then you can fetch and merge the latest from the remote repository:

git fetch
git merge origin/master

If you still are experiencing problems I would suggest contacting http://support.atlassian.com/ as it may require more information for us to diagnose the problem

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events