1.建立 github
https://github.com/
注册一个用户名。登陆后
之后 点击New
点击
Create repository
有了一个远程的仓库。
2. 添加 SSH KEY。
参考 https://help.github.com/articles/generating-ssh-keys
写的非常详细。
a. 生成 KEY
ssh-key -t rsa -C "chunhai999@gmail.com"
b. 把key拷贝到 github的设置 中。
3.clone code
git clone git@github.com:chunhai999/git-test.git
得到了一个 仓库中的README 文件。成功。