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