Can I have a repository in another repository's ignored directory?
A. S. Budden
abudden at gmail.com
Sun Nov 6 21:22:14 UTC 2022
On Sun, 6 Nov 2022, 21:02 Chris Green, <cl at isbd.net> wrote:
> This may sound like rather an odd idea but bear with me.
>
> I have a mercurial repository that I synchronise (using syncthing)
> across several systems. This works beautifully, I can use mercurial
> to manage the files on any of the several systems and it works just as
> one would hope. (there's only me using the system).
>
> I'd like to have another, independent, repository available on all
> these systems and I'd prefer not to add yet another synchronised
> directory.
>
> So, can I add a directory to the existing repository, call it say
> 'dirabc' and add it to the .hgignore of the parent repository so it is
> ignored and then create a new mercurial repository in 'dirabc'?
>
> I can't see anything wrong with doing this, am I missing anything?
>
Yes. I do this all the time, sometimes also with git repositories in the
subfolder rather than hg ones (e.g. where I want to compile my website into
a folder that's a git repository so I can push the compiled version to
github for publishing).
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mercurial-scm.org/pipermail/mercurial/attachments/20221106/03588476/attachment.html>
More information about the Mercurial
mailing list