From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms12.migadu.com with LMTPS id iJAEKaYfg2TuOgEATFOONw (envelope-from ) for ; Fri, 09 Jun 2023 14:48:38 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id ADjRKKYfg2RslAAAauVa8A (envelope-from ) for ; Fri, 09 Jun 2023 14:48:38 +0200 Received: from mail1.fsfe.org (mail1.fsfe.org [217.69.89.151]) (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 4395618791 for ; Fri, 9 Jun 2023 14:48:35 +0200 (CEST) From: jlicht@fsfe.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fsfe.org; s=2021100501; t=1686314913; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=qc021UxDeaDP5nN6qcpv801L+qO9jcSMRP4rzMl0DSY=; b=CMA4ZF+mHs+IuV07Ftq7xzgUfgehu45YJaTRYfMz0ciYtRzDkypPgrn7wlT8K1zswtXPeI Tx43Di51J0A+n6e70a9nn61tzl6DBTjqXPePktSjZrD3nX7fsW0WHTcq4uVWlZv+U/LR4H AQuR0aYiURR2hTlaJ+fngFgp3sY1ZMo= To: piem@inbox.kyleam.com Cc: Jelle Licht Subject: [PATCH v2 4/5] gnus: Add support for matching inbox by X-GNU-PR-PACKAGE header. Date: Fri, 9 Jun 2023 14:48:28 +0200 Message-Id: <20230609124829.29629-5-jlicht@fsfe.org> In-Reply-To: <20230609124829.29629-1-jlicht@fsfe.org> References: <20230608165926.12586-1-jlicht@fsfe.org> <20230609124829.29629-1-jlicht@fsfe.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Migadu-Country: DE X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=kyleam.com; s=key1; t=1686314918; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=qc021UxDeaDP5nN6qcpv801L+qO9jcSMRP4rzMl0DSY=; b=C3E9pHP691sb0qHPouSj3Z8q1Nnb3Zz0eBHTZ+Zf9SzTkHjbBZ5QSPaKvo2Pb9oI+ERB2H MXJJ3ikGf+o1SA2voZ8O505hQ4QbtZ6a4sOYqzISuS/sFClYLerkyohN2WwENtgXFx/Fup ksNsPcOvr6xi4VjTPE5BvUeujEmBOavHq7cwsuXzJNe/sfs8ESEnKDgDIamZWP6L9ByrW1 JhL1wp7lS8YJAffQP3dAdomZTiy9sC6jo66lgY74niQqcRZjqdOwiEHbF3fKJEWQFy4Jr2 FyU4CK+93kJxOA3xlFLrk4SfXKy4HqTJbJTUKvmsmhgUEoMpJ0WAeW4A05N8Aw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=fsfe.org header.s=2021100501 header.b=CMA4ZF+m; dmarc=pass (policy=none) header.from=fsfe.org; spf=pass (aspmx1.migadu.com: domain of jlicht@fsfe.org designates 217.69.89.151 as permitted sender) smtp.mailfrom=jlicht@fsfe.org ARC-Seal: i=1; s=key1; d=kyleam.com; t=1686314918; a=rsa-sha256; cv=none; b=rhmfLdXrFgoyjtEmXnktnMUtmIHwsq+ryGHwO2oHTS7/7iix1WX5/H2e0tvvyY/9Og3plT /GkoJiFpQ5zAwPXkphf4yWIieIN2Py+F1D/GATV2/fUaAAfazD8HhzR0Y3aeriX2c8E1+l axZIPd6KmGR8Jf5xch+BQng0UJOd7F101WkH3UQ4GFjAxO//Gy3994mH3W4u0pQHB5dxOB JDoQslpkmxs/YCmk3GVN10mGBebL0LsemOKzwdlanZk8o/NT6iB6pnfIaKFVPcdYpMmddr zPdZkVjxyo4jNs3aQRVPF4W51Lr85WC2SnAg/eE/C170vRxSRrI8i7yZz+vxVQ== X-Migadu-Scanner: scn1.migadu.com X-Migadu-Spam-Score: -6.18 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=fsfe.org header.s=2021100501 header.b=CMA4ZF+m; dmarc=pass (policy=none) header.from=fsfe.org; spf=pass (aspmx1.migadu.com: domain of jlicht@fsfe.org designates 217.69.89.151 as permitted sender) smtp.mailfrom=jlicht@fsfe.org X-Migadu-Queue-Id: 4395618791 X-Spam-Score: -6.18 X-TUID: mkyWe//s+/7l From: Jelle Licht --- piem-gnus.el | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/piem-gnus.el b/piem-gnus.el index e8e5f1e..25b80b7 100644 --- a/piem-gnus.el +++ b/piem-gnus.el @@ -42,7 +42,11 @@ "Return inbox name from a Gnus article" (when (derived-mode-p 'gnus-article-mode 'gnus-summary-mode) (with-current-buffer gnus-original-article-buffer - (piem-inbox-by-header-match)))) + (or (piem-inbox-by-header-match) + (let ((gnu-package + (car (piem--message-fetch-decoded-fields + '("x-gnu-pr-package"))))) + (piem-inbox-by-gnu-package-match gnu-package)))))) (defun piem-gnus-get-mid () "Return the message ID of a Gnus article." -- 2.40.1