Git initial configuration and configuration github

After 1, configure the user name and mailbox (here is my github username and mailbox configured), execute the following command in the C: there will be a global file .gitconfig under \ Users \ yaosq disk.

config git - , Ltd. Free Join user.name "here put your username"

config git - , Ltd. Free Join user.email "here and put your mailbox."

Configuring ssh-key value of the machine (Note: I have been here Press Enter password is empty set), enter the following command:

SSH -keygen -t rsa -C "here and put your mailbox."

After executing the command will require three or four times to confirm:

Save route confirmation secret key (if not directly change the transport path);
if the top on the lower step has a stored secret key file path, it is necessary to confirm overwriting (if the secret key is no longer needed before the transport directly coverage, such as the need to manually copied to another directory is then covered);
create a password (if no password directly enter);
confirm password;
execution as shown below:

After the implementation, in the specified save path will generate two files named id_rsa.pub and id_rsa of:

 The id_rsa.pub copy into github repository remote ssh to go. , Name taken lightly.

 

 

After saving, the following for verification, enter the following command: initial need to confirm yes, will survive in the known_hosts file to the .ssh.

ssh -T [email protected]

 

See hi .... indicates success.

 

 

References: https://www.cnblogs.com/idiv/p/9889147.html

https://blog.csdn.net/lqlqlq007/article/details/78983879

Guess you like

Origin www.cnblogs.com/ysq0908/p/11203973.html