how to commit code in bitbucket code example

Example 1: how to push code to bitbucket

git remote add origin <the URL for your Bitbucket repository> 
git push -u origin master

Example 2: how to commit code to bitbucket first time

git init
git add --all
git commit -m "Initial Commit"
git remote add origin <the URL for your Bitbucket repository> 
git push -u origin master

Example 3: how to push code to bitbucket

git init
git add --all
git commit -m "Initial Commit"