[Source code management] Bitbucket free library sharing

Source: Internet
Author: User

Http://blog.csdn.net/zxciop110/article/details/7830199

 

We recommend several free version libraries. I will not introduce GitHub here, gitorious and gitorious because GitHub charges fees for private libraries, and the earliest gitorious is unable to build private libraries. Open Source helps many people, but if you are a small team looking for a better one if there is a free version library, we recommend that you use Bitbucket to create a free private library. The capacity is infinitely large, and a team of five people and small teams can work with the Development Project. Below I will share the steps for creating a Bitbucket.

How to Use Bitbucket

I. Software and SSH keys:

Because my Bitbucket account has the same email address and user name as GitHub, ssh public keys can use GitHub to log on to Bitbucket and click "Account" in the user name boliquan ", click "SSH keys" on the left to set
The software does not need to be installed.

2. Create and upload a private project:

After logging on, hover your mouse over "repositories" and select "create repositories". "name" indicates the project name, such as ylife. "private" is selected by default"
Select "Git" for "repository type" and select the "language" used by the project"
"Description" indicates the description, and "website" indicates the publishing address.
The private project has a small lock icon.
Create a Bitbucket folder on disk D, create another ylife folder, and put the project file in it. Right-click the "Git Bash" folder and the command box appears.

[Plain]
View plaincopyprint?
  1. Git init input this
  2. Git Add. Add all files (just prepare locally, note that "." indicates all files)
  3. Git commit-M 'version 1.2.6 'refers to the description in quotation marks
  4. Git remote add origin git@bitbucket.org: boliquan/ylife. Git
  5. Git push origin master upload steps are now complete
Git init input this git add. add all files (just prepare them locally, pay attention to the ". git commit-M 'version 1.2.6 'quotes indicate the information git remote add origin git@bitbucket.org: boliquan/ylife. gitgit push origin master upload steps have been completed here

If you want to access the https://bitbucket.org/boliquan/ylife/ directly go to the source code page, click "admin", "landing page" select "Source", here you can also set a lot of things, for example, you can select "private" as the private database, and uncheck this option to change to a public database.

3. Modify and upload local files

After modifying the local file, right-click "Git Bash" in the "ylife" folder and the command box appears.

[Plain]
View plaincopyprint?

  1. If the content is added, git add first.
  2. Git commit-a-m 'version 1.2.6 'modification (local)
  3. Git pushes origin master modification (server). You can find that the modification has been made on the Bitbucket website.
If the content is added, git add first. git commit-a-m 'version 1.2.6 'modification (local) git push origin master modification (server). You can find that the modification has been made on the Bitbucket website.

4. Create a tag:

In the "ylife" folder, right-click "Git Bash" and the command box appears.

[Plain]
View plaincopyprint?
  1. Git tag-A 1.2.6-M 'version 1.2.6'
  2. Git push -- tags, you can see the created tag on the Bitbucket website.
Git tag-A 1.2.6-M 'version 1.2.6 'indicates the GIT push -- tags. You can view the created tag on the Bitbucket website.

5. delete a tag
In the "ylife" folder, right-click "Git Bash" and the command box appears.

[Plain]
View plaincopyprint?
  1. Git tag-D 1.2.6 Delete this tag (local)
  2. Git push origin: refs/tags/1.2.6 Delete this tag (server), then you can find that the tag on the Bitbucket is missing
Git tag-D 1.2.6 Delete this tag (local) git push origin: refs/tags/1.2.6 Delete this tag (server), then you can find that the tag on the Bitbucket is missing

6. Download a project from the server

Right-click "Git Bash" in the "Bitbucket" folder and the command box appears.

[Plain]
View plaincopyprint?
  1. Git clone git@bitbucket.org: boliquan/ylife. Git will download to a folder named "ylife" and the source code
Git clone git@bitbucket.org: boliquan/ylife. Git will download to a folder named "ylife" and the source code

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.