First, you first need to download their own good Git , turtle (TortoiseGit ) and registration code cloud account
- After installing Git, if the Git installation path is changed, you need to change it in the registry editor yourself. The specific operation can be done
- Code cloud account password needs to know
- There are those who don’t know can save the mother
2. Preparations
1. Create a new folder or your own project folder, and right-click after entering, as shown in the figure below. After
I changed the path to the original path, the icon will be restored after the computer restarts
. 2. Generate a local The key, let it be associated with the key on the code cloud. The
ssh-keygen -t rsa -C “13******[email protected]”
following is your own mailbox, mine is the same mailbox as the code cloud, and then press Enter until the green font appears, such as the following picture:
this At that time, your local will generate 2 files, the address of the file is in the above picture content, the key file:, id_rsa.pub
or then output the command: cat ~/.ssh/id_rsa.pub
to view
3. Go to the official website of Code Cloud here and log in to your account
- Set SSH public key
- Create warehouse
- Then enter our folder again and right-click to open
Git Bash Here
(same step 1.)
to continue the command line
- Initialize first:
git init
- Then
git remote add origin https://gitee.com/xiaoyinhui/csdn-notes.git
the back of the address is the address of the warehouse, there is at last one plot- Then pull the files in the warehouse to the local:
git pull origin master
if it succeeds, there will be the pulled files locally, if it fails, see the failure prompt
- After initialization, a hidden folder will be generated
.git
, if not, find the option to show hidden files
- This has been completed and can be pulled. I will use the tortoise to add and submit the push (the code cloud warehouse will not have the file you submitted if there is no push), the test is OK
Take a few notes so you can read them later.