Git 使用

一、场景及方案

 1、本地只想提交部分代码,然后关联远程分支

git init
git remote add origin git@gitlab.snowballtech.com:iot/api_smartlock.git
touch README.md
git add README.md
git commit -m "add README"
git push -u origin master
git checkout -b local
git add .
git commit -m 'first commit'
git checkout -b develop

    git push origin develop:develop

  

posted on 2019-10-31 14:31  levi~liu  阅读(113)  评论(0)    收藏  举报

导航