there is an error in my ubuntu 16.04LTS at input method, so before I fix it, I have to use Eng to write my blog temporarilly
below is refered to coding.net help
1.the first step is to generate a SSH key locally, enter below in console
ssh-keygen -t rsa -b 4096 -C "email@example.com"
2.copy the content in
id_rsa.pub to the website to add a SSH key
3.after SSH key is successfully added to the website, have a test to make the host website trust your instrument
ssh -T firstname.lastname@example.org
if return the successful info, then you can add a remote origin to a specified git
git remote add origin https://git.coding.net/Username/ProjectName
if encountered a problem, like:
sign_and_send_pubkey: signing failed: agent refused operation
this will failed our push, s solution is answered in askubuntu
. It explains that
ssh-agent is running already but it can not find any keys attached. Solve problem:
then, the problem is fixed.