From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id qAVcD2qb5GHMBwEAgWs5BA (envelope-from ) for ; Sun, 16 Jan 2022 23:25:46 +0100 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id gEqwDGqb5GGoNgAA9RJhRA (envelope-from ) for ; Sun, 16 Jan 2022 23:25:46 +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 1C2ED21509 for ; Sun, 16 Jan 2022 23:25:46 +0100 (CET) Received: from yantan.tethera.net (localhost [127.0.0.1]) by mail.notmuchmail.org (Postfix) with ESMTP id E07B25F529; Sun, 16 Jan 2022 22:25:41 +0000 (UTC) Received: from eggs.gnu.org (eggs.gnu.org [209.51.188.92]) by mail.notmuchmail.org (Postfix) with ESMTPS id 44F0A5F402 for ; Sun, 16 Jan 2022 22:25:39 +0000 (UTC) Received: from [2001:470:142:3::e] (port=54182 helo=fencepost.gnu.org) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n9Dxw-00073u-SK; Sun, 16 Jan 2022 17:25:36 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:Date:References:In-Reply-To:Subject:To: From; bh=aq6Dur4L2ovr0RhGnZPvzEakPUR5bvqp5i1X/6nV7Ig=; b=PM67fUv7JQ4b9dUgx2Qn p2Xmn1XA8p4MlzFG95wgBJcDFOhElRR7WamZSx8X8K4A+rNiq057J60mzkU+01acp4jXkWeLCffRx 65/YhLD01+zQ3vRNrp8B9MmOAvQhzzkhGBsls7TBwsOEkVXJZAlG00Czzc6GPdZOdhc6628Rxf4vo objaac8/xHZlfAk6BiyXGTNhPZ1wngRRRRF6ZNOGlTAdI5zbo20p0K4Iy5eYcbWwuG5/rqm1J47Bd G4nrjxyGcAcH2MWv/jN73DKlDy7BGBf3sc0Y4uKEzfZChZEsUrXzmxtfK0X+rgwrZFIyVjodd04jQ NDZ7LWxg3AXpNg==; Received: from cpc103048-sgyl39-2-0-cust502.18-2.cable.virginm.net ([92.233.85.247]:33554 helo=rivendell.localdomain) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n9DxW-0006d1-5u; Sun, 16 Jan 2022 17:25:36 -0500 Received: from localhost (rivendell.localdomain [local]) by rivendell.localdomain (OpenSMTPD) with ESMTPA id db1a0706; Sun, 16 Jan 2022 22:25:06 +0000 (UTC) From: Jose A Ortega Ruiz To: Kyle Meyer Subject: Re: [PATCH v4] emacs: customizable names for search buffers In-Reply-To: <878rvfmnc2.fsf@kyleam.com> References: <20220110181644.1457631-1-jao@gnu.org> <87h7a7uuhz.fsf@gnus.jao.io> <878rvfmnc2.fsf@kyleam.com> X-Attribution: jao X-Clacks-Overhead: GNU Terry Pratchett X-URL: Date: Sun, 16 Jan 2022 22:25:06 +0000 Message-ID: <87zgnv1fp9.fsf@gnus.jao.io> MIME-Version: 1.0 Message-ID-Hash: 45MSE32LPKCF2GL42JHVJO6GIJNDHD7J X-Message-ID-Hash: 45MSE32LPKCF2GL42JHVJO6GIJNDHD7J X-MailFrom: jao@gnu.org X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-notmuch.notmuchmail.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: notmuch@notmuchmail.org 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 Authentication-Results: aspmx1.migadu.com; none X-Migadu-Scanner: scn1.migadu.com X-TUID: yvJmF+R+UWG2 On Sun, Jan 16 2022, Kyle Meyer wrote: > Jose A Ortega Ruiz writes: > >> yeah, that's what i use and didn't notice my error above. format-spec >> is much nicer than a plain regexp subs, one can use format specifiers >> like %3t and many others, but unfortunately seems to have been >> introduced in emacs 27. > > format-spec has been present in Emacs since version 21.1, specifically > c113de23613 (2000-09-19). (Some parameters have been added since then, > but you only use FORMAT and SPECIFICATION in your patch.) > > Here's a test with Emacs 25, Notmuch's current minimum (if I grep > correctly): > > (emacs-version) ; => "GNU Emacs 25.3.50.1 ..." > (require 'format-spec) > (format-spec "%b" '((?b . "fine"))) ; => "fine" > > At first I thought you were getting confused by the fact that > format-spec has been marked as autoloaded only recently, but it looks > like that was in 0185d76e742 (Fix and extend format-spec (bug#41758), > 2020-06-18), which will be part of the 28.1 release. So that's not > consistent with "introduced in emacs 27". In very recent emacs (i'm using its master branch, actually), if one M-x describe-function RET format-spec one sees in the help buffer: Probably introduced at or before Emacs version 27.1. that's where my misconception came from. I guess that's potentially good news: i don't see an emacs version specified in notmuch's package: is it supposed to be compatible with emacs < 25.3? If not, we can just forget about the regexp branch. Thanks a lot for checking, jao -- "The evil that is in the world almost always comes of ignorance, and good intentions may do as much harm as malevolence if they lack understanding." - Albert Camus