In the software development field we need to use version control system which can allow to share source code in between team members so all can work on one project. Visual source safe is one of the best example for that. As IT industries expanded their business across the globe and today scenario is like on one project developers from more then one country working on, and to share and manage that project there are plenty source code hosting available including SVN, Github, Bitbucket etc..
If you are newer and would like to know about Github you can read my previous post on Introduction to Github.
Github & bitbucket are git based provider and github is very famous in market today however they are not providing Private repository for Free account. In the opposite side Bitbucket is providing unlimited private & public repository for free user. In short comparison in terms of private source code (repository) github is Paid source code hosting provider & bitbucket is Free source code hosting provider
Step by step - Create new repository & upload on bitbucket
Now to communicate with this repository you need Git or Mercurial (protocols).
First step you require to download Git. if you are window user and working with Visual studio then you can use GitExtension to integrate Git source control to it.
After Installing git you can follow the step to connect you project directory with repository which we have created in above step and upload it with just simple commands
Open Git Bash and go to project directory and type following commands.
1) cd "Path of your direcotry"
Go to your project directory which you want to upload.
2) git init
Initialize git configuration for that directory
3) git add remote "name" "https/ssh path"
Add remote with https or ssh path to communicate with bitbucket
4) git add .
It will add all list of files need to add in commit
5) git commit -m "helptext"
It will commit all added files with message in local directory
6) git config --global user.name "username"
git config --global user.email "email"
On commit if you haven't configure then it will ask about user's name & email to track user information
7) git push -u master
Finally it will push all committed files to repository on bitbucket.
After this you can see the content we have pushed on bitbucket as below
No comments:
Post a Comment