开发者

Cloning just a particular directory with hg?

I come from a Subversion background, but I am slowly migrating to Mercurial.

When starting on many of my projects, I would setup a development environment that was configured to a particular starting point in developing an app/webapp/program (much like a Maven 2 archetype, but not necessarily Java/Maven).

Later I would checkout this archetype/template project out of my svn repo by its particular path; and than export the working copy from version control by the repository; so that I could import the working copy back in to another repository without adding the changes that I made to the working copy to the base the template/archetype project.

I've 开发者_Python百科tried doing the same thing in Mercurial, and I've run into a wall since I can't check out, er..um..no, clone a specific path from the hg repository.

If I want to achieve the same sort of functionality using Mercurial, what should I do?

Use tagged branches? The archetypes/template projects are very different, but I'd like to keep them in the same repository.


The repository is a much more lightweight concept in Mercurial. Although you said you would like to avoid it, I would probably create a separate repository in this situation. In situations where you require a shared history between your repositories, you can use the ShareExtension.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜