hgrc.5.text FILES content, ordering implied?

Matt Mackall mpm at selenic.com
Mon Aug 31 19:32:35 CDT 2009

On Thu, 2009-08-27 at 11:43 -0400, Douglas Philips wrote:
> On or about 2009 Aug 27, at 11:22 AM, Steve Borho indited:
> > On Thu, Aug 27, 2009 at 10:06 AM, Martin Geisler<mg at lazybytes.net>  
> > wrote:
> >> I'm not sure there is a "need" as such -- it is enough if Mercurial
> >> would load one file on each system, especially now that a config file
> >> can include other config files (so both .hgrc and Mercurial.ini could
> >> include a file with common settings).
> >>
> >> Would you prefer Mercurial to load only Mercurial.ini on Windows and
> >> only .hgrc on Unix, and that we deprecate the .hgrc file on Windows?
> >
> > Does anyone run Mercurial on cygwin?  Does that platform use the
> > windows version of util or the posix version?  The only reason to
> > support ~/.hgrc on the Windows platform, IMHO,  is for cygwin.
> I run cygwin under XP. Its the only way I can stay semi-sane at work. :)
> The thing is, that doesn't matter, because the Python that Hg and THg  
> use is a windows native Python, so all the file paths (for hooks,  
> etc.) are all completely different. Across the various *nix, *BSD,  
> etc. systems I can use symlinks, etc. in the filesystem to keep the  
> insanity manageable. :)
> So, to answer Martin's question, yes, I would love it if Windows only  
> loaded Mercurial.ini files, but, there is a >year old patch that  
> explicitly changed that. I have no idea how to find out why, and I'm  
> expected Matt's clue-by-four to come swinging in, singing the  
> "backwards compatibility" tune. :)

Yep, we can't change it. It's entirely possible that Unix users with
Windows forced on them have discovered that .hgrc files work and have
stuck with them. Possibly they've got cross-platform home directories
via Samba. It's even possible they're relying on both files getting read
on Windows only to get some Windows-specific behavior.

So we should probably document it more precisely.

http://selenic.com : development and support for Mercurial and Linux

More information about the Mercurial-devel mailing list