From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.migadu.com ([2001:41d0:403:4876::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms8.migadu.com with LMTPS id KJoXJrpPdGUDGwAAG6o9tA:P1 (envelope-from ) for ; Sat, 09 Dec 2023 12:30:02 +0100 Received: from aspmx1.migadu.com ([2001:41d0:403:4876::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id KJoXJrpPdGUDGwAAG6o9tA (envelope-from ) for ; Sat, 09 Dec 2023 12:30:02 +0100 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 2AF145A871 for ; Sat, 9 Dec 2023 12:30:02 +0100 (CET) Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b="E/Z4S96X"; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=posteo.net ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1702121402; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=UaXqejSO4BmuMfmYQiPHLJ6XWhx5yYpQqxyTfOf+nbA=; b=CeCvdl1ozCIN5+2Xp73PD4dXk7QUPmgo8wWJtv7gh+rJqS/4Bm1SF49OIFallrZT8KQ+Hx WfP1gdqKg+/XWwW05F8AkXeDkquJf4LMO+Rb/bhc+8kMhn74w0UVHNQR4L4E3J346JSybD 3R1l4vkM8ByYMoLxwzgDSoNjdc/ri9KxBH10H9DOb2zDIpfiNNZQppeTwRhQjhqDKlPokJ xltsq8o1olcIhuhqIr9bIdWD7R1l0hzY/zS165a+ZVMOBi97rW9BUevr+NQckKmeZ9TYBf +t8yv+LwmbUzbZuNnxLtstNDovjTN6u7RX2aGY1ZVaF1VoQav0ZS8R4apPii/w== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b="E/Z4S96X"; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=posteo.net ARC-Seal: i=1; s=key1; d=yhetil.org; t=1702121402; a=rsa-sha256; cv=none; b=hH3BYV4EEK3Pn7AeNv7opJ2z+ahZkACRt9lZv2jepIB5xFXB7x8u6RvUGToSMOmTQmIOZx a8aOjXpldNz5XYqNnsrhP4cUMoSXTRmypBDBVhOpEtyL/U1Vp9luYZQgaHoCkHflxQrFDe s2EmRydzgHA3IqQr3kcnjcZc3HzM7IwpQySchDKdmeuRDFSLFKs3oRCafz5LY8cc4CwXiz PWCHScNg7FSbe4wbaNsUTIs9fG0ScN9AA7aFliKtPAw0+IUHrGxpJmk6E/Y9tdSE1p0Dck X07vJU2/JQ9rzNqBDC5k6CfxFgA99aHG70bkoBela7mIMwGTtDWLojcjq+hugA== Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rBvWc-00015E-A0; Sat, 09 Dec 2023 06:29:38 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rBvWa-000151-Ki for emacs-orgmode@gnu.org; Sat, 09 Dec 2023 06:29:36 -0500 Received: from mout02.posteo.de ([185.67.36.66]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rBvWY-0001PJ-6H for emacs-orgmode@gnu.org; Sat, 09 Dec 2023 06:29:36 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout02.posteo.de (Postfix) with ESMTPS id 93775240104 for ; Sat, 9 Dec 2023 12:29:31 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1702121371; bh=jePJKKiOfEbaJEuYb6derii8i5getzGLLi7ffmH7D/8=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version:From; b=E/Z4S96X9U1dWKP5+Ix8g8fH9OkkkJOyCgdZAEib4fQ+7EJlQlNOqWT6e90BvqWI9 z+zoQLjwYwYzihPsODtNl0G/fI8rD4xFCOYRO8uR+s301fehXg28+Il5ZD69NXvZGK 9tAMAvBKVbZYpz1MO4k2YGue93ppTMsfU05m9T0FKkqBjRAflJu0tb/x6VhdGjKpQ4 xINtgRCm42g/8idLEq+9L3tQNOB5ycgMwxDDMDeMFGJeP7Jp8i+kvPfcBfKN0mdzgN XvKw7+atJppZ8kc0FCtnaMDMMdYO+sDqERAsd6OGnlrGZgLl8JxFRWTg9j22j+UmyQ ftPSHsmF/7fiQ== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4SnQlH1fPYz9rxQ; Sat, 9 Dec 2023 12:29:31 +0100 (CET) From: Ihor Radchenko To: Max Nikulin Cc: emacs-orgmode@gnu.org Subject: Re: Completion of links to man pages In-Reply-To: References: Date: Sat, 09 Dec 2023 11:32:39 +0000 Message-ID: <877clnsjag.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=185.67.36.66; envelope-from=yantar92@posteo.net; helo=mout02.posteo.de X-Spam_score_int: -43 X-Spam_score: -4.4 X-Spam_bar: ---- X-Spam_report: (-4.4 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H5=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: emacs-orgmode-bounces+larch=yhetil.org@gnu.org X-Migadu-Country: US X-Migadu-Flow: FLOW_IN X-Migadu-Spam-Score: -8.61 X-Spam-Score: -8.61 X-Migadu-Queue-Id: 2AF145A871 X-Migadu-Scanner: mx10.migadu.com X-TUID: MSQ5wbyK7z2u Max Nikulin writes: > I am unsure if the code below is appropriate for :complete property of > "man" link. It does not rely on any double-dash functions or variables, > but it still uses some implementation details since there is no suitable > high level functions in man.el and woman.el from Emacs. > > (defun org-man-complete (&optional _arg) > "Helper for completion of links to man pages." > (concat > "man:" > (let ((completion-ignore-case t)) ; See `man' comments. > (funcall > (if (eq org-man-command 'woman) > #'org-man--complete-woman > #'org-man--complete-man) > "Manual entry: ")))) > > (defun org-man--complete-man (prompt) > (require 'man) > (let (Man-completion-cache) > (completing-read > prompt > 'Man-completion-table))) > ... Considering that the discussion on emacs-devel concluded that woman is obsolete, that no interest has been shown in introducing a stable completion API, and that the "man" part of the above code is reasonably simple, I think that the above two functions would be an OK addition to ol-man (with woman part of `org-man-complete' removed). Max, may you convert this into a patch? -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at