From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Mekeor Melire Newsgroups: gmane.emacs.bugs Subject: bug#68970: 30.0.50; Info.el: Info-url-alist should support format-sequence that encodes "Top" node as "index" Date: Wed, 07 Feb 2024 22:10:25 +0000 Message-ID: <8734u352rm.fsf@posteo.de> References: <87fry44bz6.fsf@posteo.de> <867cjgz5rm.fsf@gnu.org> <87bk8s3usi.fsf@posteo.de> <86le7wxc3e.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="38259"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Eli Zaretskii To: 68970@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Feb 07 23:28:08 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1rXqOm-0009a0-OZ for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 07 Feb 2024 23:28:08 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rXqOU-000816-TC; Wed, 07 Feb 2024 17:27:50 -0500 Original-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 1rXqOS-00080c-Lr for bug-gnu-emacs@gnu.org; Wed, 07 Feb 2024 17:27:48 -0500 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rXqOS-0004Pd-7y for bug-gnu-emacs@gnu.org; Wed, 07 Feb 2024 17:27:48 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rXqOg-0003fs-50 for bug-gnu-emacs@gnu.org; Wed, 07 Feb 2024 17:28:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Mekeor Melire Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 07 Feb 2024 22:28:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 68970 X-GNU-PR-Package: emacs Original-Received: via spool by 68970-submit@debbugs.gnu.org id=B68970.170734485314090 (code B ref 68970); Wed, 07 Feb 2024 22:28:02 +0000 Original-Received: (at 68970) by debbugs.gnu.org; 7 Feb 2024 22:27:33 +0000 Original-Received: from localhost ([127.0.0.1]:58135 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rXqOC-0003fC-T2 for submit@debbugs.gnu.org; Wed, 07 Feb 2024 17:27:33 -0500 Original-Received: from mout01.posteo.de ([185.67.36.65]:55409) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rXqOA-0003ey-Ml for 68970@debbugs.gnu.org; Wed, 07 Feb 2024 17:27:31 -0500 Original-Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id F0448240028 for <68970@debbugs.gnu.org>; Wed, 7 Feb 2024 23:27:10 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.de; s=2017; t=1707344831; bh=SjRohwt9SMsyK7pB+qMhzqVB7SPkw6blpFxpDql/hYg=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version:Content-Type: From; b=ffWU/1s/nnFKED//l5tMxnoS1wludoxVHz9IEZNUxX0Ofl2hkARrIqqXuxeWn1pUN szZCa6zHh6Wgd8yTbZnyjPysxJmUrgGlzv/9s+0Sn0apViBoFBspo3O4orBQ3xd5vI SW42sGWY5RNyoAezisRwqT4GV1IrGASTst3EvLcwL6JkFybLW8ZuE8gZXQMrDw5v/r vpD8VKsBmMDTQASnitDtEr7qs4n7lSKtLjMaimSl75rQ9vnlKxDcX0FhI3g5kAzXQh VVNvplDhd/A65hL0khFpgEaIJzig71dEPkES4lcAP8RSEqolO/iiFQg98w/xQG47QF zlCXvA2CuCCdQ== Original-Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4TVZVQ19y7z6tvc; Wed, 7 Feb 2024 23:27:10 +0100 (CET) In-reply-to: <86le7wxc3e.fsf@gnu.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:279587 Archived-At: 2024-02-07 22:18 eliz@gnu.org: > > Let's assume we have a manual with "Top" node as well as a node called > > "Foo". Let's further assume the webserver is configured so that > > example.com/Foo does not resolve to example.com/Foo.html but rather > > results in "not found". > > Why would we assume a strange configuration like that? That's not > what happens on gnu.org, for example. Which documentation sites that > offer Texinfo-derived manuals have such configurations? Yes, gnu.org does allow to omit the .html suffix. I am working on an Emacs package that will provide more entries to Info-url-alist. That's why I have a tentative list, as you requested, at hand, indeed. Here's a list of entries that require a .html suffix: (("annotate" "bfd" "ctf-spec" "gdb" "stabs") "https://sourceware.org/gdb/current/onlinedocs/gdb/%i.html") (("as" "bfd" "binutils" "ld" "gprof") "https://sourceware.org/binutils/docs/%m/%i.html") (("cc-mode") "https://cc-mode.sourceforge.net/html-manual/%i.html") (("cgdb") "https://cgdb.github.io/docs/%i.html") (("chickadee") "https://files.dthompson.us/docs/chickadee/latest/%i.html") (("cuirass" "guix") "https://guix.gnu.org/%m/manual/html_node/%i.html") (("forge" "magit" "ghub" "transient" "magit-section" "with-editor") "https://magit.vc/manual/%m/%i.html") (("gnutls" "gnutls-client-server-use-case" "gnutls-crypto-layers" "gnutls-handshake-sequence" "gnutls-handshake-state" "gnutls-internals" "gnutls-layers" "gnutls-logo" "gnutls-modauth" "gnutls-x509" "pkcs11-vision") "https://gnutls.org/manual/html_node/%i.html") (("guile-algorithms") "https://guile-algorithms.lajszczak.dev/%i.html") (("guile-email") "https://guile-email.systemreboot.net/manual/dev/en/%i.html") (("gwl") "https://guixwl.org/manual/html_node/%i.html") (("haskell-mode") "https://haskell.github.io/%m/manual/latest/%i.html") (("haunt") "https://files.dthompson.us/docs/%m/latest/%i.html") (("libc") "https://sourceware.org/%m/manual/html_node/%i.html") (("mailutils") "https://mailutils.org/manual/html_node/%i.html") (("mercury" "mercury_faq" "mercury_library" "mercury_ref" "mercury_trans_guide" "mercury_user_guide") "https://mercurylang.org/information/doc-release/%m/%i.html") (("org") "https://orgmode.org/manual/%i.html") (("orgguide") "https://orgmode.org/guide/%i.html") (("zsh") "https://zsh.sourceforge.io/Doc/Release/%i.html") (Note that some domains are duplicated here.) Here's a tentative list of non-gnu.org online manual URLs that work without .html suffix: (("7400-1" "7400-1-hidden" "analysis" "ckt" "clocks" "coordinate-space" "lepton-manual" "lepton-scheme" "net-attribute" "path-example" "rf_cascade" "text-layout") "https://lepton-eda.github.io/%m.html/%e") (("emacs-shroud") "https://www.nongnu.org/emacs-shroud/manual/html_node/%e") (("emacsy") "https://www.nongnu.org/emacsy/manual/html_node/%e") (("geiser") "https://www.nongnu.org/geiser/%e") (("gnutls-guile") "https://gnutls.gitlab.io/guile/manual/html_node/%e") (("guile-proba") "https://luis-felipe.gitlab.io/%m/manual/%e") (("guile-shapefile") "https://hugonikanor.github.io/guile-shapefile/%e") (("octave") "https://docs.octave.org/latest/%e") (("optionmatrix") "https://anthonybradford.github.io/optionmatrix/%e") (("polipo") "https://www.irif.fr/~jch/software/%m/manual/%e") (("sawfish") "https://sawfish.tuxfamily.org/%m.html/%e") (("scm" "Xlibscm" "hobbit" "slib" "r5rs") "https://people.csail.mit.edu/jaffer/%m/%e") (("slime") "https://slime.common-lisp.dev/doc/html/%e") As you can see the .html-requiring-case is very common. It would be nice if users can conveniently use a string in this case, rather than going for a function. > > This is why the user must choose to use example.com/%e.html as > > URL-specification currently. But then they have the problem that the > > "Top" node is translated to example.com/.html. > > > > I suggested to add another format-sequence, %i, that translates the > > "Top" node as "index". Thus, example.com/%i.html would translate to > > example.com/index.html in case of "Top". > > I understand, but the overlap in functionality between %e and %i is > got to cause some confusion, so if there's a way to avoid that, I'd > prefer it. The code intentionally produces an empty string for "Top", > and there's a good reason for it doing so. The "good reason" is only to keep URLs a little shorter, if possible, for ease on eyes. :) Another idea would be to let users specify two URL-SPECs: One for the Top-node; another for non-Top nodes. Another idea would be to only provide one format-sequence, for sake of simplicity, namely one that works with .html-suffix-requiring-URLs. And use that format-sequence in the default value of Info-url-alist. The default URLs would be a little longer then.