From bca4618f58e801f20776c48ae5773702369f9139 Mon Sep 17 00:00:00 2001 From: Sam Rabin Date: Wed, 2 Oct 2024 21:57:51 -0600 Subject: [PATCH 01/40] Point doc-builder to my fork. Avoid old fork of sphinx_rtd_theme. Based on https://github.com/ESMCI/cime/pull/4613. Builds OK, but I'm not sure if the new versions setup works. --- .gitmodules | 4 +- doc/doc-builder | 2 +- doc/source/_static/pop_ver.js | 37 ----------------- doc/source/_templates/layout.html | 3 -- doc/source/_templates/versions.html | 64 +++++++++++++++++++++++++++++ doc/source/conf.py | 16 +++++++- 6 files changed, 81 insertions(+), 45 deletions(-) delete mode 100644 doc/source/_static/pop_ver.js delete mode 100644 doc/source/_templates/layout.html create mode 100644 doc/source/_templates/versions.html diff --git a/.gitmodules b/.gitmodules index 7274b9acd2..d60b9bf157 100644 --- a/.gitmodules +++ b/.gitmodules @@ -123,8 +123,8 @@ fxDONOTUSEurl = https://github.com/NCAR/ParallelIO [submodule "doc-builder"] path = doc/doc-builder -url = https://github.com/ESMCI/doc-builder -fxtag = v1.0.8 +url = https://github.com/samsrabin/doc-builder +fxtag = 30d2d6d48549f68ee300a469af5dfe5ac3eeae81 fxrequired = ToplevelOptional # Standard Fork to compare to with "git fleximod test" to ensure personal forks aren't committed fxDONOTUSEurl = https://github.com/ESMCI/doc-builder diff --git a/doc/doc-builder b/doc/doc-builder index ab9bc93dd0..30d2d6d485 160000 --- a/doc/doc-builder +++ b/doc/doc-builder @@ -1 +1 @@ -Subproject commit ab9bc93dd09d0173f8097c7a18c7d061c1cd3b79 +Subproject commit 30d2d6d48549f68ee300a469af5dfe5ac3eeae81 diff --git a/doc/source/_static/pop_ver.js b/doc/source/_static/pop_ver.js deleted file mode 100644 index b8c58658a8..0000000000 --- a/doc/source/_static/pop_ver.js +++ /dev/null @@ -1,37 +0,0 @@ -$(document).ready(function() { - /* For a URL that looks like - https://blah.github.io/versions/VERSIONFOO/html/bar/index.html, set cur_version_dir to - 'VERSIONFOO' (i.e., the portion of the path following 'versions'). - */ - var proj_end = document.baseURI.indexOf("versions") + 9; - var end = document.baseURI.indexOf("/", proj_end); - var cur_version_dir = document.baseURI.substring(proj_end, end); - var mylist = $("#version-list"); - mylist.empty(); - $.getJSON(version_json_loc, function(data) { - if (data.hasOwnProperty(cur_version_dir)) { - /* First add the current version so that it appears first in the drop-down - menu and starts as the selected element of the menu. If you click on the - current version, you should stay at the current page. - - The conditional around this block should generally be true, but we check it - just in case the current version is missing from the versions.json file for - some reason. - */ - cur_version_name = data[cur_version_dir]; - mylist.append($("