目录
方法 一
- 新建 gitlab项目haha
简略步骤:
(base) E:\09-code\02-wind_profile>git remote add origin http://12.36.171.165/zhaoxiaozheng/haha.git
(base) E:\09-code\02-wind_profile>git push -u origin master
复杂过程:
(base) E:\09-code\02-wind_profile>git remote add origin http://12.36.171.165/zhaoxiaozheng/haha.git
error: remote origin already exists.
(base) E:\09-code\02-wind_profile>git remote -v
origin http://12.36.171.165/zhaoxiaozheng/wind_profile_cluster.git (fetch)
origin http://12.36.171.165/zhaoxiaozheng/wind_profile_cluster.git (push)
orign http://12.36.171.165/zhaoxiaozheng/test.git (fetch)
orign http://12.36.171.165/zhaoxiaozheng/test.git (push)
(base) E:\09-code\02-wind_profile>git remote rm origin
(base) E:\09-code\02-wind_profile>git remote rm orign
(base) E:\09-code\02-wind_profile>git remote -v
origin http://12.36.171.165/zhaoxiaozheng/haha.git (fetch)
origin http://12.36.171.165/zhaoxiaozheng/haha.git (push)
(base) E:\09-code\02-wind_profile>git push -u origin master
Enumerating objects: 1239, done.
Counting objects: 100% (1239/1239), done.
Delta compression using up to 8 threads
Compressing objects: 100% (1214/1214), done.
Writing objects: 100% (1239/1239), 12.70 MiB | 2.75 MiB/s, done.
Total 1239 (delta 151), reused 0 (delta 0), pack-reused 0
remote: Resolving deltas: 100% (151/151), done.
To http://10.35.161.175/zhaoxiaozheng/haha.git
* [new branch] master -> master
branch 'master' set up to track 'origin/master'.
push 成功!!!