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

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

Gaurav Bhavsar May 31, 2017

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 vote
Jobin Kuruvilla [Adaptavist]
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 31, 2017

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 Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events