autonity / docs.autonity.org

Documentation for the Autonity Go Client (AGC)
https://docs.autonity.org
2 stars 6 forks source link

Drop the use of custom `page-meta-links.html` partial layout #131

Open aiman opened 10 months ago

aiman commented 10 months ago

Description

Currently this project override Docsy's page-meta-links.html partial layout due to an issue where the gh_repo_path was not being set correctly.

More specifically, the default has:

  {{ $gh_repo_path := printf "%s/content/%s" $gh_branch $pathFormatted -}}

whereas what we need is:

  {{ $gh_repo_path := printf "%s/content/docs/%s" $gh_branch $pathFormatted -}}

This was solved by using an override layouts/partials/page-meta-links.html. Note the comment at the top of the file:

<!--
    Override Docsy `page-meta-links.html` to set the $gh_repo_path correctly.
    This fixes the issue described in Docsy #138 and #296. This file must be
    kept in sync with Docsy updates.
-->

Note also this issue is mentioned in the Makefile upgrade target:

    @echo "Remember to check that 'layouts/partials/page-meta-links.html' is" \
          "kept in sync with any changes to" \
          "'themes/docsy/layouts/partials/page-meta-links.html'."

Since these changes were implemented, it seems the Docsy issues 138 and 296 have been fixed upstream, but it's not clear this will allow us to use the upstream layout unmodified.

If this issue is indeed fixed in a new Hugo upstream version, then we can use that version and drop the custom partial layout as well as remove the reminder in the Makefile.

cmjc commented 6 months ago

@dwengo given #148 - the site is now running on Quarto - so can this issue now be closed as legacy and wontfix?