1、在码云注册一个账户
2、创建一个项目


3、设置ssh公钥


4、把生成的公钥添加到码云

5、windows某一位置


6、git init (初始化仓库)
7、关联远程仓库
git remote add origin 你的远程库地址
如:git remote add origin https://github.com/cade8800/ionic-demo.git
8、git add . 文件 或 git add -A 或 git add . (提交文件)
9、git commit -m '注释' (提交文件)
10、推送到远程仓库
git push -u origin master
tips:这步可能要填写码云的账号密码
tips: 推送到远程仓库可能报错

大概原因就是 意思是本地和远程的文件应该合并后才能上传本地的新文件
tips: https://blog.csdn.net/winnershili/article/details/78888548
11、git pull origin master (拉取远程仓库文件合并)
这步报错

运行:git pull origin master --allow-unrelated-histories
12、重复步骤8,9,10
网友评论