Why we need commit & Push?why cant we have Push only

Hi All,

I am new to bitbucket, till now I have worked on TFS ( Microsoft).In TFS user has local workspace(working directory) and simply pushes changes to Global ( remote) repository.

 

Here in BitBucket we commit first. And once all changes are commited ,we push all in one go.

MY query:

what benefit we get having commit and then push. What if we dont have commit in bit bucket and straightway push?

 

Regards,

GBhavsar

1 answer

1 votes

The simple answer is that "it is the GIT way". Git lets you work offline and commit happens locally. You need to push only when you need your code to be in the central repo. It is not a restriction on the Bitbucket end.

You might want to read more about Git to understand the difference between the Git way and the old checkin/checkout way.

Having said that, tools like SourceTree and EGit has an option to commit and push in a single click. You can use it if you really want to.

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...

673 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