Questions tagged [subrepos]

Mercurial can include other repositories in a checkout. These repositories are called subrepositories.

More information:

101 questions
4
votes
3 answers

Is it possible to peg a Mercurial subrepo to a specific revision (like svn:externals)?

I'm migrating a set of projects from Subversion to Mercurial. The projects currently use svn:externals to pull code from one into the others. I've been following the recommendation to point externals to a specific revision number and manually update…
Tara McGrew
  • 1,987
  • 19
  • 28
4
votes
5 answers

Does mercurial-server support subrepo?

I installed mercurial-server on one of my machines, cloned my project there, it has 3 subrepos, and when I try to clone it back to another location I get an error: remote: mercurial-server: Cannot create repo under existing repo abort: no…
Esteban Feldman
  • 3,288
  • 6
  • 32
  • 31
4
votes
0 answers

Mercurial - race condition when pushing with subrepos

With a fairly basic subrepo structure like this: parent parent/subrepo1 parent/subrepo2 Race conditions tend to occur when multiple users push changes at the same time. Simple example: User 1 & 2 begin pushing. User 1 skips parent/subrepo1,…
Salami
  • 1,048
  • 1
  • 10
  • 17
3
votes
1 answer

Workflow with mercurial subrepositories

My project uses a mercurial repository and is developed under Linux. It also depends on a "common" library, which we wish to share with other projects. The solution I'm currently considering is to put the library in a mercurial subrepository, and…
Itay Perl
  • 12,844
  • 3
  • 18
  • 12
3
votes
3 answers

Mercurial Subrepositories - Do you have to commit in the subrepository and then commit on the main repository?

Using TortoiseHg 2.1.3 and Hg 1.9.2. No matter what I do, the parent repo is not seeing new files created in the subrepo unless I first commit them in the subrepo. I thought all commits and pushes were only supposed to be done on the parent repo?
jpshook
  • 4,834
  • 6
  • 36
  • 45
3
votes
1 answer

How to push Mercurial subrepositories to their own origin

I am using subrepositories to share code between multiple projects. I keep the "master" version of these shared repositories in a central location. That way I can easily push changes I made to them in one project and pull them in another. That…
Karsten
  • 1,814
  • 2
  • 17
  • 32
3
votes
2 answers

Mercurial sub-repositories

I read the tutorial many times and I feel that I am still missing something. I'll just try to give a concrete scenario. Please help me find where I'm wrong. Suppose I have a repository which everyone considers as "central". This means that every…
3
votes
1 answer

mercurial subrepos at the current revision of a specific branch

I'm quite new to mercurial, I've read a lot of topics on this subject but I still can't understand if I can achieve what I'm trying to do. Basically I'd be interested in cloning the current revision of a branch from a main repository and its…
user533784
  • 121
  • 1
  • 4
3
votes
1 answer

How to deal with target name conflicts between Mercurial repositories and subrepositories?

My Mercurial repository repo1 has a custom target named foo; never mind what it does. I also have another repository repo2, which which I want to use as a subrepo of repo1. repo2 is developed in a similar fashion to repo1, and also has a custom…
einpoklum
  • 118,144
  • 57
  • 340
  • 684
3
votes
1 answer

Keeping third-party libraries under a Mercurial project: Sub-repos or not?

We are developing a closed-source project, versionned with Mercurial. We are using two libraries in our project : One of those libraries is being developed by a third-party. They are using git, and we usually just pull from their repo once in a…
gregschlom
  • 4,825
  • 4
  • 28
  • 23
3
votes
2 answers

Mercurial Subrepos, how to control which changeset I want to use for a subrepo?

I am reading up on subrepos, and have been running some tests locally, seems to work OK so far, but I have one question. How do I specify/control which changeset I want to use for a particular subrepo? For instance, let's say I have the following…
Lasse V. Karlsen
  • 380,855
  • 102
  • 628
  • 825
3
votes
1 answer

How do I get changes to propagate to all subrepos in Mercurial?

I have recently switched from Subversion to Mercurial for source control and in doing so have split up one repository into several. I used subrepos to manage the dependencies between repositories. The problem is that pull is not suprepo aware so I…
CoreyD
  • 220
  • 1
  • 3
  • 8
3
votes
2 answers

Git inside git: disconnect inner git, keep files

Summary Git inside git. Removed the inner .gits, kept the files. Push. Clone. Folders exist, but are empty. What I'm trying to do So I'm trying to upload an existing repo to my own git server. The repo has some repos inside of it (that are not a…
krivar
  • 342
  • 1
  • 3
  • 16
3
votes
3 answers

hg serve for subrepos

I have a repo with subrepos, and would like to do hg serve. On other computer, I tried hg clone http://address:8000/ new_repo Scenario 1: when my original repo had, in .hgsub, lines of the form: sub_repo_1 = sub_repo_1 sub_repo_2 = sub_repo_2 I…
Thalia
  • 13,637
  • 22
  • 96
  • 190
3
votes
1 answer

How do you add a subrepository properly

I have a repository called main and underneath it a number of subrepositories. When initially created the main superrepository, I had taken already existing repositories and copied them into the main folder, then added the .hgsub file to indicate…
Piotr
  • 541
  • 4
  • 19