git push origin not working

Hi.

Basically I have same difficulty like at

https://answers.atlassian.com/questions/67729/git-push-origin-not-working

I commit, push but I not see updates at Bitbucket.

My repository is private and only 2 BitBucket accounts have access there:
*) me - owner

*) other account in read-only mode

Thanks in advance.

Best regards, Konstantin

3 answers

1 accepted

Konstantin,

You don't say what kind of response your client returns you when you push. Is the push failing or does it appear to succeed? It is a good idea to paste the response here.

Your first step is to see which remote your configuration is set to push to. You can do this with this command:

git remote origin

If you are on HG, you can list the contents of .hg/hgrc in your local repo to see the remotes.

By the way - I can't to delete my "answer"

Hi. Thanks for the quick reply.

>You don't say what kind of response your client returns you when you push.
To be consistent:
Win 8 x64
client: msysgit

client response:
$ git push origin master
Everything up-to-date

It was not the first push to this repository and before that everything was fine.

$ git log
I see my last commits but I have not seen same commits at BitBucket

After
$ git checkout master
I lost all updates which I made before but, fortunately, I made backup of files.

So now I restored last state of files in repository (but without history).
And now I'm more interested why this occurred.

Konstantin,

So, it appears you made some changes but did not add them to the staging area. So, the process is this:

  1. Add or edit a file in your repository.
  2. Stage the file with this command:
    git add myfile.txt
  3. Repeat until are your changes are made.
  4. Commit all changes in staging with this command:
    git commit -m "message"
  5. Push your changes:
    git push origin master

>git add myfile.txt

>git commit -m "message"

>git push origin master

Yes, I know about this sequence.

And as I wrote

> $ git log
> I see my last commits but I have not seen same commits at BitBucket

Hi. Thanks for the quick reply.

>You don't say what kind of response your client returns you when you push.
To be consistent:
Win 8 x64
client: msysgit

client response:
$ git push origin master
Everything up-to-date

It was not the first push to this repository and before that everything was fine.

$ git log
I see my last commits but I have not seen same commits at BitBucket

After
$ git checkout master
I lost all updates which I made before but, fortunately, I made backup of files.

So now I restored last state of files in repository (but without history).
And now I'm more interested why this occurred.

Suggest an answer

Log in or Join to answer
Community showcase
Piotr Plewa
Published Dec 27, 2017 in Bitbucket

Recipe: Deploying AWS Lambda functions with Bitbucket Pipelines

Bitbucket Pipelines helps me manage and automate a number of serverless deployments to AWS Lambda and this is how I do it. I'm building Node.js Lambda functions using node-lambda&nbsp...

652 views 0 4
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
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot