[PATCH RFC] clone: copy hgrc paths if source and dest are local

Adrian Buehlmann adrian at cadifra.com
Wed Jun 16 13:08:29 CDT 2010


On 14.06.2010 15:41, Greg Ward wrote:
> On Sun, Jun 13, 2010 at 2:13 PM, Adrian Buehlmann <adrian at cadifra.com> wrote:
>> It's not possible to setup subgroups of global paths though.
>>
>> For example, when doing a GUI (TortoiseHg in my case), we show a list of
>> all paths available (repo.ui.configitems('paths')) for a repo, which
>> then includes all global paths (let's assume there is one global
>> 'mercurial.ini' or 'hgrc' for the user with those global paths).
> 
> I like the proposed feature, but then I never configure [paths]
> outside of a per-repo hgrc.  I prefer manually copying [paths] around
> to having the wrong path available.

Which is what I do as well, but I found out that it is due to how
suboptimal path aliases are handled currently in mercurial. I found it
out after pondering about our new GUI for the upcoming (Nov 1st)
TortoiseHg 2.0 (Qt rewrite/port).

Maintaining path aliases in a single place would make a lot more sense.

But it looks like the local cloning feature is dropping in significance
more and more over time anyway. Especially for those working with lots
of branches. People tend to have a smaller number of local clones.

> But if you do configure [paths] in you ~/.hgrc (or Mercurial.ini,
> whatever), here's an idea: "hg showconfig --debug" knows where each
> config setting comes from.  The information is in there somewhere.  So
> could you use that when cloning to copy only the [paths] from
> src_repo's local config?
> 

Thanks for all the replies folks and for sharing your thoughts. I'm not
interested in pursuing this anymore.

For those interested in the upcoming TortoiseHg 2.0: We're now anyway
going to throw out the path nodes we currently have in the reporegistry
widget (see the screenshot link already posted).

(back to my non-walled GUI garden on the most hated platform with lots
of users :-)



More information about the Mercurial-devel mailing list