看看现在远程连到哪:
git remote -v
origin http://gousheng@gerrit.gousheng.com:8081/product/tina/gousheng-doc (fetch)
origin http://gousheng@gerrit.gousheng.com:8081/product/tina/gousheng-doc (push)
到gerrit上看看远程的地址是什么,加到ssh远程里:
gerrtt网页-Prohect- 搜索doc-看看SSH对应的地址
remote add ssh ssh://gousheng@gerrit.gousheng.com:29418/product/gousheng/gousheng-doc
git remote -v
origin http://gousheng@gerrit.gousheng.com:8081/product/gousheng/gousheng-doc (fetch)
origin http://gousheng@gerrit.gousheng.com:8081/product/gousheng/gousheng-doc (push)
ssh ssh://gousheng@gerrit.gousheng.com:29418/product/gousheng/gousheng-doc (fetch)
ssh ssh://gousheng@gerrit.gousheng.com:29418/product/gousheng/gousheng-doc (push)
看看分支是什么:
git branch
master
分支是master
把本地的修改ssh推到远程对应的分支
git push ssh master:refs/for/master