Problem: one hg repository has a file that I want to update and save in another hg repository, and I don't want to copy and paste. I want the file to be available in both repositories.
Scenario:
Work with product 0001
Project A has an hg repository.
Down, Project B is evolving. There is basically no connection between projects A and B, but there are some files that can be shared.
File versioning in a managed approach is critical: copy & paste is not a viable solution.
There are some solutions that may work -
- Combining both repositories in a repo. But this means that version numbers for a set of files will change due to outflows elsewhere. In addition, different projects are not very connected.
- Convert both into sub-class. I'm not sure if this is the right approach, subrepos seems to have some kind of ridiculous behavior related to parent repo. (Or are they used to?)
Extending this problem is the concept of sharing certain files between products. One way or another, the file must be exchanged and properly tracked as a separate file, but in two different products.
A common problem can be indicated like this -
Given a set of products, each of which has its own repository under development, which is divided and developed on files living in each other's repositories (think of utility routines and frameworks), what is an hg solution for constant support of the file version between products.
What is a good solution here?
source share