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

git push doesn't update to latest set of files on a repo branch

Khuram Malik February 6, 2013

I have a master branch. My colleague forked this, and made some changes to some of the html files. Her and I worked on separate files at the same time.

She's since done a compare and git pull, and has also done a

  • git add .
  • git commit -m "commit message"
  • git push -u origin master

But her repository on bitbucket does not show the latest update of files.

I understand that when there is a working tree that by design, git doesn't push updated files, and there is some way of forcing it or something? Or perhaps there's more to this?

Any advice?

1 answer

0 votes
aMarcus
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
February 11, 2013

This seems unusual. Check the following:

git status

Make sure that the files that were changed aren't sitting waiting to be added still.

git log --stat

To see what files were changed in the commits, going backward from the most recent.

git config -l

Be sure that the user is pushing to the correct repo. Their config should look similar, but with the correct owner and repo name filled in.

remote.origin.fetch=+refs/heads/*:refs/remotes/origin/*
remote.origin.url=git@bitbucket.org:{username}/{repo slug}.git

On Bitbucket, be sure to check the commit view to see if the most recent commits there match what is local

https://bitbucket.org/{username}/{repo slug}/commits/all

Also, check to be sure the user isn't working in a branch. More information on branches and how to view them can be found here.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events