From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id YPgzBYzAMmJgzAAAgWs5BA (envelope-from ) for ; Thu, 17 Mar 2022 06:01:00 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id 4P77AYzAMmLbAwAAauVa8A (envelope-from ) for ; Thu, 17 Mar 2022 06:01:00 +0100 Received: from mail.notmuchmail.org (yantan.tethera.net [135.181.149.255]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id B00FE2D70A for ; Thu, 17 Mar 2022 06:00:59 +0100 (CET) Received: from yantan.tethera.net (localhost [127.0.0.1]) by mail.notmuchmail.org (Postfix) with ESMTP id 982A95F709; Thu, 17 Mar 2022 04:54:07 +0000 (UTC) Received: from mail-pl1-x633.google.com (mail-pl1-x633.google.com [IPv6:2607:f8b0:4864:20::633]) by mail.notmuchmail.org (Postfix) with ESMTPS id 70BA25F6F1 for ; Thu, 17 Mar 2022 04:54:04 +0000 (UTC) Received: by mail-pl1-x633.google.com with SMTP id n15so3556651plh.2 for ; Wed, 16 Mar 2022 21:54:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:in-reply-to:references:date:message-id :mime-version; bh=RbvdLB0KnaFm6EUKO0HSFOuhk69VhDn1ZhywSnp7BaQ=; b=jfFHME6gVDEF7gIm1Acw2cDkN9T+uEEXojFOd9UlPX8W0vRukPxEvohLhbOv8oy4ew JDOZEhb+kM81fRRpEbreUXeWZlxCcDFOam+pu7dYmvb0/5oSyn4P7lU1YdlT583FmNOg mehl4RWXy/U9kkzWUCAVYxUnCnq/7RCBLOcKFpCat1ahqDlP+3/DDHD80IdrUPhRTJNK F2PB8wj3AvjEqG2UyHlHCRanfQv1mRyMwaylfuJVEOT6xNri2NITOPsrehTLifClwtcO ASL/ksIJeg5AGHIPpabUFbw/DjNy9i5SH/AAMc6B5u8Nj10z4/BeJGrYENTBtrbfozzC 0bUA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:in-reply-to:references:date :message-id:mime-version; bh=RbvdLB0KnaFm6EUKO0HSFOuhk69VhDn1ZhywSnp7BaQ=; b=S8XbWaTfU+vRGMO25NX+H2IdDEfsGC8snaImvrhfi6a1r3l6O/nEDMFk9nrxE8lwwD eixZxTE8WFR+7lobxyNNZxVciuZIk6wztrOUxHNSKvFc55/Fg6lgODib3Q5HtikMV0ox S6jMtLSFHwx78PJI/Y0tKukKV7SOwkDmdeB4r+EoN1B0iTdVXvH7n5/LUBJy4LThFwZm 5s9tpjH5IgcL94hTqlzjA9nKoL1MM1ieqyaMabQpGJ2ZXCWZCr2CGKNIKuqgOx1OGXkz A9OvYs2ceybsMrYN6utMS//1nQWqvPeyCu/6m66pCcGZDJEZKarkj59qw/Dbc2MkviVs AcKw== X-Gm-Message-State: AOAM533VexRsYs9gqJt4qtw4tjqE9sAkDzhKOUeRfYlbbX/YlaNZRlg2 rouC2QLbIV2yLb8wqdh4WHs= X-Google-Smtp-Source: ABdhPJxhnnoTpMGB2WJdb5jw39S2O75WqIigVd9PoG39Tr//RdX6/vzXfecq0qQNEK8PAFLvoKJXBA== X-Received: by 2002:a17:902:f60f:b0:151:4f66:55b4 with SMTP id n15-20020a170902f60f00b001514f6655b4mr2918742plg.127.1647492842655; Wed, 16 Mar 2022 21:54:02 -0700 (PDT) Received: from localhost ([43.230.66.58]) by smtp.gmail.com with ESMTPSA id d15-20020a056a00198f00b004f7109da1c4sm4974592pfl.205.2022.03.16.21.54.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 16 Mar 2022 21:54:02 -0700 (PDT) From: Utkarsh Singh To: Alexander Adolf Subject: Re: [PATCH] emacs: Add more front ends for address completion In-Reply-To: <389f3bb5fbbf532ce8e6ba0dc25c8e97@condition-alpha.com> References: <87bkzhbez9.fsf@gmail.com> <115f4649ac25dff4073a32dba70e6db7@condition-alpha.com> <87wnhfjrer.fsf@gmail.com> <871qzfzgic.fsf@gmail.com> <3444ac96512ebdb53fb1faf90a2db263@condition-alpha.com> <87k0d4n8tr.fsf@gmail.com> <87ee3clysa.fsf@gmail.com> <87ee36v7ax.fsf@gmail.com> <389f3bb5fbbf532ce8e6ba0dc25c8e97@condition-alpha.com> Date: Thu, 17 Mar 2022 10:26:17 +0530 Message-ID: <87y219yy6m.fsf@gmail.com> MIME-Version: 1.0 Message-ID-Hash: VQHBYJXI6CJ36PAY3W2BUFATXCYOSFFD X-Message-ID-Hash: VQHBYJXI6CJ36PAY3W2BUFATXCYOSFFD X-MailFrom: utkarsh190601@gmail.com X-Mailman-Rule-Hits: nonmember-moderation X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-notmuch.notmuchmail.org-0 CC: Notmuch mailing list X-Mailman-Version: 3.3.3 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Migadu-Flow: FLOW_IN X-Migadu-To: larch@yhetil.org X-Migadu-Country: DE ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1647493259; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-owner:list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=kWPc5Gi26litZ6zx+8CdcTlw+0i9VjI/CMFIoIjXISw=; b=GcYimcLo++JJYxJkObUuBeJd8EPsRDFAD6mHLJkXWoTrsFVVJnJwv7h5EGelFykfEEln4c kjxtP3P29B851HQ9unZQMuewoxTKHV49yeOzLD4QQtvWlwOfVNwtgQ36jjKJ6sjZvMKgib wQwd+n/l+uJiEqz1m+fS6A6fRK8BQ04vuD+8BLeMFv1oQVMk4KtVuBQgRGXJwa6VVtLi1H kg//gLw3CX2vBPZrbF8Proo8v9vU92p8eVwppkOeZBFbXC1hFCLmtnjRHFtwO6bLDZ98a9 6XtO9B5c2JKe0zpyaTw7lrkdWV8Zvs24nsLtLP1LrSuL8jktlYlMicnIntxBMg== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1647493259; a=rsa-sha256; cv=none; b=orK9a6n+xheHKSATxF8jEY3AAL7i5UXp5lz24ZLn7gjgySHakkMwaeQB0gOpGkBks3qGxp JCJr6x7DoxCodIfeBSXghwC4f7sn8jxHFLPgARSZPKatyi7HH1OPHfMV4NnPS5QeNu5nXS CqObDfzilYVqtQ5tnv5Ao2EGjRlqMjC17G2qWBoXfuu33afpla0WBoEGQTn7+L5mueBKjx Uq44TY68LYsWFnbvarAIzX3GUN1J8/vsZGLVz8lOlxaWc+llh2xbhJWDsc5F9phFNnoJVf 3brXrqxREbJ+hViB+Hgto1jm/pN/EobPNk6mZ8fy8OxkMBGT1QRNDRr41Xgy/w== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("body hash did not verify") header.d=gmail.com header.s=20210112 header.b=jfFHME6g; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of notmuch-bounces@notmuchmail.org designates 135.181.149.255 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Migadu-Spam-Score: 6.81 Authentication-Results: aspmx1.migadu.com; dkim=fail ("body hash did not verify") header.d=gmail.com header.s=20210112 header.b=jfFHME6g; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of notmuch-bounces@notmuchmail.org designates 135.181.149.255 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Migadu-Queue-Id: B00FE2D70A X-Spam-Score: 6.81 X-Migadu-Scanner: scn0.migadu.com X-TUID: IzOvsQU+OF4/ On 2022-03-15, 13:37 +0100, Alexander Adolf wrote: > Utkarsh Singh writes: > >> [...] >>>> `post-completion': Called after a completion candidate has been inserted >>>> into the buffer. The second argument is the candidate. Can be used to >>>> modify it, e.g. to expand a snippet. >>>> [...] >>> >>> Hm, that sounds like it would functionally be similar to specifying an >>> :exit-function property in completion-extra-properties? >> >> Great! We can definitely work with this. >> [...] > > I'm glad to learn we might be heading in the same direction. AFAIR you > spoke about removing company from notmuch-address.el altogether? That > would be by impetus, too. > > EUDC [1], which is part of core Emacs, has just been given the ability > to combine search results from several sources [2]. > > [1] https://www.gnu.org/software/emacs/manual/html_mono/eudc.html > [2] https://github.com/emacs-mirror/emacs/commit/0470a4a939772c4bd25123b15f5eadab41f8bee5 > > I have written experimental code to make EUDC contribute to > completion-at-point, and to make notmuch-address contribute to EUDC > search results. This works in principle, and I get combined search > results from notmuch-address, and the macOS Contacts app in a corfu > pop-over UI in header fields of message-mode. It seems you were looking > for something similar? Honestly, I didn't knew about EUDC, but it looks promising. > With this kind of setup, the overall architecture for email address > completion could be like this: > > notmuch-address \ > BBDB | > LDAP > --> EUDC --+ > macOS Contacts | | > ... / V > | > +----------<-------------+ > | > V / completing-read > | | corfu > + --> completion-at-point --> < company > | ... > \ > > This would remove any user interface related code from > notmuch-address.el, an instead convert it into a back-end for EUDC. > > Looking forward to your thoughts, Thank you for working on this issue. But from now, its up to Notmuch maintainers to decide whether or not they want any improvements in `notmuch-address.el'. -- Utkarsh Singh https://utkarshsingh.xyz/