<div dir="ltr"><br><br><div class="gmail_quote"><div dir="ltr">Mads Kiilerich <<a href="mailto:mads@kiilerich.com">mads@kiilerich.com</a>> schrieb am Sa., 24. Sep. 2016 um 18:09 Uhr:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On 09/24/2016 03:21 PM, Thomas De Schampheleire wrote:<br>
> Hi,<br>
><br>
> Some of the Kallihea developers have an account on 'our-own-kallithea'<br>
> which they use to publish proposed Kallithea changes via a pull<br>
> request. This is all fine for the regular Kallithea developers that<br>
> also have an account there, but such pull requests are not by default<br>
> advertised to the mailing list.<br>
<br>
+1 from me.<br>
<br>
Perhaps base it on Dominik's changes for per repo configuration (which<br>
we really should get around to land ...) so we can upstream it.<br>
<br></blockquote><div>Yeah about that. Is there some thing missing from my part?</div><div>What is holding it back?</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
/Mads<br>
<br>
<br>
><br>
> I wonder if it is much more complex than following code (to be added<br>
> on OOK only):<br>
><br>
> diff --git a/kallithea/model/notification.py b/kallithea/model/notification.py<br>
> --- a/kallithea/model/notification.py<br>
> +++ b/kallithea/model/notification.py<br>
> @@ -106,6 +106,17 @@ class NotificationModel(BaseModel):<br>
>           if 'threading' in email_kwargs:<br>
>               headers = {'References': ' '.join('<%s>' % x for x in<br>
> email_kwargs['threading'])}<br>
><br>
> +        # also send to mailing list<br>
> +        if type_ in (Notification.TYPE_PULL_REQUEST,<br>
> Notification.TYPE_PULL_REQUEST_COMMENT,<br>
> Notification.TYPE_CHANGESET_COMMENT):<br>
> +            class DummyUser(object):<br>
> +                """Stub of User class, avoiding add to database"""<br>
> +                def __init__(self, email):<br>
> +                    self.email = email<br>
> +<br>
> +            # TODO check if mailing lists are to be sent for this repo<br>
> +            log.debug('Additionally sending notification (type %s to<br>
> mailing list', type_)<br>
> +            rec_objs.add(DummyUser('<a href="mailto:kallithea@example.com" target="_blank">kallithea@example.com</a>'))<br>
> +<br>
>           # send email with notification to all other participants<br>
>           for rec in rec_objs:<br>
>               ## this is passed into template<br>
><br>
><br>
> Where the TODO needs to be still handled...<br>
><br>
> Thanks,<br>
> Thomas<br>
> _______________________________________________<br>
> kallithea-general mailing list<br>
> <a href="mailto:kallithea-general@sfconservancy.org" target="_blank">kallithea-general@sfconservancy.org</a><br>
> <a href="http://lists.sfconservancy.org/mailman/listinfo/kallithea-general" rel="noreferrer" target="_blank">http://lists.sfconservancy.org/mailman/listinfo/kallithea-general</a><br>
<br>
<br>
_______________________________________________<br>
kallithea-general mailing list<br>
<a href="mailto:kallithea-general@sfconservancy.org" target="_blank">kallithea-general@sfconservancy.org</a><br>
<a href="http://lists.sfconservancy.org/mailman/listinfo/kallithea-general" rel="noreferrer" target="_blank">http://lists.sfconservancy.org/mailman/listinfo/kallithea-general</a><br>
</blockquote></div></div>