importing a git working directory to a second git repository
git version 1.7.4.1
Ubuntu
Currently I am working on a project at my company. Our git repository is on our local LAN server.
I have a private repository on unfuddle.
So I have cloned my project on my work's company and created some branches that I am currently working on.
I have a branched called ie work_branch.
I am wondering if I can import that work_branch into my unfuddle respository. However, I don't want to do this if it will affect my current working copy of my git repostory at work.
So basically I just want to add to this unfuddle repository. So I can push my changes to it. As well as our LAN Server.
Many thanks for any suggestions,
From your repository on your work computer you can just push your branch called work_branch
to your unfuddle repository. First you have to set up a "remote" that refers to your unfuddle repository, eg:
git remote add unfuddle <URL-of-the-unfuddle-repository>
Thereafter you can push the branch to that respository with:
git push unfuddle work_branch
You are looking for git submodules.
Check this docs
链接地址: http://www.djcxy.com/p/16048.html上一篇: 在.gitattributes文件中忽略text = auto
下一篇: 将git工作目录导入第二个git存储库