[PATCH 5 of 5 RFC] patchbomb: add support for a file that configures default To and CC

Sean Farley sean at farley.io
Wed Jun 14 21:15:16 EDT 2017


Augie Fackler <raf at durin42.com> writes:

>> On Jun 14, 2017, at 10:17, Yuya Nishihara <yuya at tcha.org> wrote:
>> 
>> On Tue, 13 Jun 2017 18:50:27 -0400, Augie Fackler wrote:
>>> Durham had the idea of a tweak to patchbomb that would let us not do https://www.mercurial-scm.org/wiki/Herald.
>>> 
>>> I implemented filesets for the RFC, but I think we should probably also allow reset-based subscriptions too (e.g. "histedit" as a keyword or similar). I'd appreciate any feedback people have, since this was a quick project and it feels like it might have some real utility.
>> 
>> Looks pretty nice.
>> 
>>>> @@ -3036,12 +3036,17 @@ Test hg email defaults settings:
>>>>> [devel.setsubscriptions]
>>>>> c or d = c-or-d at example.com
>>>>> a or b = a-or-b at example.com
>>>> +  > [foo.setsubscriptions]
>>>> +  > binary() = hates-binary-files at example.com
>> 
>> Perhaps the config syntax could be arbitrary_key:attr = value.
>> 
>>  hatebin:fileset = binary()
>>  hatebin:revset = keyword(binary)
>>  hatebin:cc = hates-binary-files at example.com
>
> Hmm. This feels a little quirky to me somehow (though it's in-line with how we handle them in config files generally). Could we instead do something like this?
>
>> [devel]
>> to = devel at example.com
>> cc = always-cc at example.com
>> 
>> [devel.hatebin]
>> fileset = binary()
>> revset = keyword(binary)
>> cc = hates-binary-files at example.com
>> 
>> [devel.a-or-b]
>> fileset = a or b
>> cc = a-or-b at example.com
>
> That looks a little cleaner to me, but I don't feel especially strongly. Just seems like we may as well use the fact that we're not in a main config file to our advantage and use sections in a slightly clearer way...

When I read Yuya's suggestion, it felt more natural than [devel.a-or-b].
I'd prefer to keep Mercurial's config-looking stuff to be a single
style. I don't mind if we wholesale switch to something like tomal; I
just don't want to have to support both.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 800 bytes
Desc: not available
URL: <http://www.mercurial-scm.org/pipermail/mercurial-devel/attachments/20170614/8de7a417/attachment.sig>


More information about the Mercurial-devel mailing list