Mac install and use git to download code steps

Source: Internet
Author: User

1. Install Git and Xcode on your Mac computer: Download directly from AppStore;

2. register your GitHub account https://github.com/-->pricing and Signup-->create a free account: if it is for work, you can register one directly with your work ID;

3. Create SSH: Create this to download git code

Open Terminal in Local:

$CD ~/.ssh Check if SSH is already present

If it exists, first make an existing SSH backup, or build the new SSH into a different directory

If not present, SSH is generated directly from the default parameters

The build process is as follows:

$ssh-keygen-t rsa-c [email protected] (email when you register for GitHub);

Follow the prompts to enter the password, you can also do not enter the password, complete the operation;

4. After the 3rd step, the file is generated under the local default path:/users/twer/.ssh/id_rsa.pub;

5. Add SSH to GitHub:

Login to GitHub, select account settings-->ssh public Keys to add SSH

Title:[email protected]

Key: Open the Id_rsa.pub file you generated and copy the contents to the relevant command line:

Pbcopy < ~/.ssh/id_rsa.pub

====== above, your account is tied to git =====

====== the following steps to download the corresponding code from git =====

1. Open the terminal, CD to the required local directory, execute the command line: Git pull Http:..........*.git


Mac install and use git to download code steps

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.