[PATCH 1 of 2] showconfig: add --edit option for editing .hg/hgrc

Benoit Boissinot bboissin at gmail.com
Thu Apr 29 04:16:09 CDT 2010


On Thu, Apr 29, 2010 at 1:51 AM, Matt Mackall <mpm at selenic.com> wrote:
> On Wed, 2010-04-28 at 18:49 -0500, Matt Mackall wrote:
>> On Thu, 2010-04-29 at 01:27 +0200, Mads Kiilerich wrote:
>> > # HG changeset patch
>> > # User Mads Kiilerich <mads at kiilerich.com>
>> > # Date 1272496822 -7200
>> > # Node ID b2096a6e1d57b1c1161da46a7f9f072c33dc4add
>> > # Parent  61b835a5a6ee897415b94acf5703d21f374b4999
>> > showconfig: add --edit option for editing .hg/hgrc
>> >
>> > Users should never touch any files in .hg - with .hg/hgrc being the primary
>> > exception.
>>
>> First, please go look at the git-config manpage to see how much more is
>> needed to have anything even close to letting us say "you don't need to
>> poke in .hg/hgrc".
>
> On closer inspection, I see this just invokes an editor rather than
> trying to manipulate options directly. But then that give us an
> inconsistency between editing ~/.hgrc, .hg/hgrc, /etc/hgrc, etc. And it
> might confuse people about where settings come from. I don't think we
> need it.

I still think we could have something better than abort for first
users who don't have an hgrc.
I can see several possibilities:
- default to askuser (and keep a message about no username, see hg help config)
- add a command to interactively create a new hgrc

Benoit


More information about the Mercurial-devel mailing list