title: Adding a Git subrepository to Mercurial
body: <p>I've been trying to set up a project using bitbucket which has project dependencies hosted on github. Using the Hg-Git Mercurial plugin I am able to almost get there.</p>
  <p>But when it comes time to push, things become troublesome.</p>
  <p>The documentation for <a href="https://www.mercurial-scm.org/wiki/Subrepositories" rel="noreferrer">Mercurial subrepositories</a> states:</p>
  <blockquote>
  <p><strong>2.4 Push</strong></p>
  <p>Mercurial will automatically attempt to first push all subrepos of the current repository when you push. This will ensure new changesets in subrepos are available when referenced by top-level repositories.</p>
  </blockquote>
  <p>But this causes a big issue since I don't want to push all the subrepositories (why would I?) — I only have read access to them, so github won't allow it. Only the main repository needs to be pushed to the remote server, but I can't figure out how to do it. <code>hg</code> wants to take control and push all subrepositories, regardless of whether or not there are changes. Is there some way to bypass this <em>feature</em>?</p>
  <p>The only things which need to be pushed are <code>.hgsub</code> and <code>.hgsubstate</code>. Once they've been pushed via alternative routes (updating to a changeset where the subrepositories don't exist), it's possible to then update and pull the changes from the remote repositories, but if I were to push again whilst on a changeset with the subrepositories, the whole ordeal repeats itself.</p>