Let’s assume you ‘ve got setup a small project locally and it’s time to add it to bitbucket.
All you need to know is: https://confluence.atlassian.com/bitbucketserver/importing-code-from-an-existing-project-776640909.html
There are a couple of details though that could make your life difficult if you don’t pay the proper attention:
- Bitbucket. Login to your bitbucket account, create a repo (but pay attention!) without adding any READMEs, nor GITIGNOREs. Repo must be empty, otherwise *push* will fail. Now, use clone button top-right corner && copy https version of the URL.
- Locally. Open your prompt to your project directory.
git init
git add --all
git commit -m "Initial Commit"
git remote add origin {{copied_url}}
git push -u origin master
Done!
Leave a Reply