Script to add (and cache) username

Marcin Kasperski Marcin.Kasperski at mekk.waw.pl
Tue Apr 22 18:34:47 UTC 2014


Matt Mackall <mpm at selenic.com> writes:

> On Wed, 2014-03-26 at 20:09 +0300, anatoly techtonik wrote:
>> Hi,
>> 
>> Does anybody has a script to prompt and add hg username to the nearest
>> .hg/hgrc config?
>
> You do know about ~/.hgrc, right? The vast majority of users only do
> this once and never think about it again.

Management of multiple identities (for example corporate vs private) is
a bit of hassle…

{ As such projects usually end up in different directories, something like
  „directory-tree-local .hgrc could help noticeably, not only for
  username, but also for things like [extra] extensions, some auth
  settings, even http proxy. Considering mercurial already merges
  settings from local repo, ~/.hgrc and /etc/mercurial/, maybe adding 
  .hgrc's lying on the path upwards from working directory toward $HOME
  would not be that horribly difficult? }




More information about the Mercurial mailing list