How to set phases.publish = false on a repo or globally on Kallithea?

Sean Farley sean at farley.io
Wed Mar 22 20:26:07 UTC 2017


Long Vu <long.vu at intelerad.com> writes:

> On Tue, Mar 21, 2017 at 6:34 PM, Sean Farley <sean at farley.io> wrote:
>> Long Vu <long.vu at intelerad.com> writes:
>>
>>> Hi,
>>>
>>> I have 0.3.2.
>>>
>>> I've been doing this for each new repo creation, when needed, by
>>> editing directly the .hg/hgrc of the repo (by going behind Kallithea's
>>> back).
>>>
>>> But I'd like to delegate this to the user creating new repos because
>>> we are rolling this out to more and more early adopters/evaluators
>>> now.  I do not want to be the bottle neck.
>>>
>>> Alternatively, how to set this globally as a default value for all new
>>> and existing repos?
>>
>> I think the easiest way to do this for Mercurial is to implement what I
>> did for Bitbucket by putting the config into the database. Once in the
>> database, all Kallithea would need to do is use this extension and set
>> an environment variable:
>>
>> https://bitbucket.org/seanfarley/hgenvconfig
>
> Alternatively, just throwing an idea here, why Kallithea do not read
> the config under /etc/mercurial/hgrc.d/ and other locations in same
> order of precedence as the mercurial command line?
>
> Then configuring global mercurial extensions/hooks for the server is
> exactly like the command line, no additional work/setup to do.

Sure, that works. But then configuration is outside of Kallithea's
django controls.

> I am actually running Kallithea in a Docker so there is no
> extensions/hooks config contamination with anything else.

Docker wasn't on our radar at the time. I would definitely recommend it
now for exactly this sort of thing.

> For people with my use case, this will be the easier option.

Sure but then there are no per-repo settings. Just something to keep in
mind as a trade-off.


More information about the kallithea-general mailing list