<p>I have two separate mercurial repositories. At this point it makes sense that they "become one" because I want to work on the two projects simultaneously.</p>

<p>I'd really like the two projects to each be a subdirectory in the new repository.</p>

<ol>
<li>How do I merge the two projects?</li>
<li>Is this a good idea, or should I
keep them separate?</li>
</ol>

<p>It seems I ought to be able to push from one repository to the other... Maybe this is really straight forward?</p>

[{'answer_id': 18175, 'author': 'nlucaroni', 'author_id': 157, 'author_profile': 'https://Stackoverflow.com/users/157', 'pm_score': 2, 'selected': False, 'text': '<p>If you aren\'t using the same code across the projects, keep them separate. You can set <em>your</em> personal repository of each of those projects to be just a directory apart. Why mix all the branches, merges, and commit comments when you don\'t have to.</p>\n\n<p><strong>About your edit:</strong> Pushing from One repository to Another. You can always use the <a href="https://www.mercurial-scm.org/wiki/TransplantExtension" rel="nofollow noreferrer"><code>transplant</code></a> command. Although, all this is really side stepping your <em>desire</em> to combine the two, so you might feel uncomfortable using my suggestions. Then you can use the forest extension, or something.</p>\n\n<pre><code>hg transplant -s REPOSITORY lower_rev:high_rev\n</code></pre>\n'}, {'answer_id': 20591, 'author': 'jm.', 'author_id': 814, 'author_profile': 'https://Stackoverflow.com/users/814', 'pm_score': 7, 'selected': True, 'text': '<p>I was able to combine my two repositories in this way:</p>\n\n<ol>\n<li>Use <code>hg clone first_repository</code> to clone one of the repositories.</li>\n<li>Use <code>hg pull -f other_repository</code> to pull the code in from the other repository.</li>\n</ol>\n\n<p>The <code>-f</code> (force) flag on the pull is the key -- it says to ignore the fact that the two repositories are not from the same source.</p>\n\n<p>Here are <a href="https://www.mercurial-scm.org/wiki/MergingUnrelatedRepositories" rel="nofollow noreferrer">the docs</a> for this feature.</p>\n'}, {'answer_id': 3723571, 'author': 'Geoffrey Zheng', 'author_id': 62479, 'author_profile': 'https://Stackoverflow.com/users/62479', 'pm_score': 3, 'selected': False, 'text': '<p>hg started to have <a href="https://www.mercurial-scm.org/wiki/Subrepositories" rel="nofollow noreferrer">subrepo</a> since 1.3 (2009-07-01). The early versions were incomplete and shaky but now it\'s pretty usable.</p>\n'}]
['https://Stackoverflow.com/questions/12843', 'https://Stackoverflow.com', 'https://Stackoverflow.com/users/814/']