Git 基础 - 克隆远程仓库到本地,修改后推送到远程
作者:互联网
[@wooluwakerdeMBP:gitLab]$ pwd /Users/walker/work/gitLab [@wooluwakerdeMBP:gitLab]$ git clone ssh://git@******.git #将远程仓库克隆到本地,会新创建wenjian目录 [@wooluwakerdeMBP:wenjian (master)]$ git remote -v #查看远程信息 origin ssh://git@******.git (fetch) origin ssh://git@******.git (push) [@wooluwakerdeMBP:gitLab]$ cd wenjian/ [@wooluwakerdeMBP:wenjian (master)]$ [@wooluwakerdeMBP:wenjian (master)]$ echo "2019年_******项目代码" >> REAMME.md [@wooluwakerdeMBP:wenjian (master)]$ git add . [@wooluwakerdeMBP:wenjian (master)]$ git commit -m'添加项目说明' [@wooluwakerdeMBP:wenjian (master)]$ git push -u origin master #将本地master分支修改的代码提交到远程master分支,-u参数:加上一次之后,后续只需要git push 即可,不需要再加上 origin master Branch 'master' set up to track remote branch 'master' from 'origin'. # 在gitlab 的 web页面上可以看到最新的推送
标签:origin,git,wenjian,gitLab,wooluwakerdeMBP,Git,master,推送,远程 来源: https://www.cnblogs.com/wooluwalker/p/12251779.html