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

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

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/*{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{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
Community showcase
Published Nov 06, 2018 in Bitbucket

Upgrade Best Practices

Hello! My name is Mark Askew and I am a Premier Support Engineer for products Bitbucket Server/Data Center, Fisheye & Crucible. Today, I want to bring the discussion that Jennifer, Matt, and ...

679 views 5 9
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you