Le 02/10/2023 à 21:37, Gavin Smith a écrit :
On Sun, Oct 01, 2023 at 06:53:30PM -0500, G. Branden Robinson wrote:
So while changing the name of the directory back to html_node will fix
some broken link problems, it won't fix them all, and it won't be robust
in the face of future development. I'm fairly neutral on the
"html_node" vs. "groff.html.node" naming issue, but I'm downright
_opposed_ to limiting my (or future contributors') flexibility in
updating, expanding, reducing, or otherwise mutating the node names of
the groff Texinfo manual. Those shackles are much too tight.
I don't want to go to the GNU site admins with requests to set up
unmaintainable-in-CVS symbolic links (or HTTP redirects in the web
server, whatever they think best) to resurrect some dead links until
we've decided this issue. So here's what I propose.
You do not need to ask GNU site admins to set up redirects for you.
You can do it with the @anchor command in Texinfo. From Info node
"(texinfo)@anchor":
... when you delete or rename a node, it is
usually a good idea to define an ‘@anchor’ with the old name. That way,
any links to the old node, whether from other Texinfo manuals or general
web pages, keep working.
https://www.gnu.org/software/texinfo/manual/texinfo/html_node/_0040anchor.html
There are other ways to redirect the html_node directory without any
help from sysadmins or webmasters.
* Create an .htaccess file, for example in the manual directory:
RedirectMatch "html_node((/.*)?)$"
/software/groff/manual/groff.html.node$1
The URL is redirected to something like this:
https://www.gnu.org/software/groff/manual/groff.html.node/*.html
* Add a line to the existing .symlinks file at the root of the groff
directory:
manual/groff.html.node manual/html_node
This symlink is processed into a rewrite directive:
RewriteRule ^/savannah-checkouts/gnu/groff/manual/html_node((/.*)?)$ \
/savannah-checkouts/gnu/groff/manual/groff.html.node$1 [R=302,L]
I think the symlink method is not as clean as .htaccess because it
replaces the standard path (gnu.org/software/groff/manual/...) with the
actual location of the manual, possibly confusing visitors:
https://www.gnu.org/savannah-checkouts/gnu/groff/manual/groff.html.node/*.html