将本地仓库推送到远程仓库里面去

git push [地址或者别名] [分支]

我这里使用的命令是 :git push project-demo master
将本地仓库文件提交到 project-demo 这个别名的地址的master分支上

  1. root@ZJJ MINGW64 /e/projectDemo (master)
  2. $ git push project-demo master
  3. Enumerating objects: 25, done.
  4. Counting objects: 100% (25/25), done.
  5. Delta compression using up to 12 threads
  6. Compressing objects: 100% (17/17), done.
  7. Writing objects: 100% (25/25), 2.29 KiB | 293.00 KiB/s, done.
  8. Total 25 (delta 7), reused 0 (delta 0)
  9. remote: Powered by GITEE.COM [GNK-6.2]
  10. To https://gitee.com/zjj19941/project-demo.git
  11. * [new branch] master -> master

有可能输入命令期间会弹出下面的框框,这个就是让你输入远程仓库的账号密码,你输入正确之后,点击确定,然后git就会继续将文件推送到你远端仓库

image.png

打开码云指定仓库之后,你发现你本地的文件提交上去了
image.png