sourceTree一个项目对应多个地址的情况

来源:互联网 发布:统计分析软件r 编辑:程序博客网 时间:2024/05/17 01:29

首先在bitbucket上创建一个仓库,终端里打开已经存在的项目的文件夹根目录,再执行下面的代码
cd /path/to/my/repo
git remote add origin https://xxxx@bitbucket.org/xxxx/happy.git
git push -u origin --all # pushes up the repo and its refs for the first time
git push origin --tags # pushes up any tags

这样做是把对应的分支情况提交;

在sourceTree的该项目设置新的远程仓库,地址就是创建的bitbucket地址,然后推送所有的分支就Ok啦
0 0