From 910faf4d8a1c712104b58e21b77333c36a79c811 Mon Sep 17 00:00:00 2001 From: Austin Macdonald Date: Tue, 9 Jun 2020 08:32:06 -0400 Subject: [PATCH] Add releases tab with versioned links * Also needed to add releases back to navbar in the layouts. --- hack/check-links.sh | 2 +- website/config.toml | 13 +++++++++--- .../partials/navbar-version-selector.html | 8 ++++++++ website/layouts/partials/navbar.html | 20 +++++++++++-------- 4 files changed, 31 insertions(+), 12 deletions(-) create mode 100644 website/layouts/partials/navbar-version-selector.html diff --git a/hack/check-links.sh b/hack/check-links.sh index 0736e981311..df2bff1ffcc 100755 --- a/hack/check-links.sh +++ b/hack/check-links.sh @@ -7,5 +7,5 @@ source ./hack/lib/common.sh header_text "Building the site and checking links" docker volume create sdk-html docker run --rm -v "$(pwd):/src" -v sdk-html:/target klakegg/hugo:0.70.0-ext-ubuntu -s website -docker run --rm -v sdk-html:/target mtlynch/htmlproofer /target --empty-alt-ignore --http-status-ignore 429 +docker run --rm -v sdk-html:/target mtlynch/htmlproofer /target --empty-alt-ignore --http-status-ignore 429 --allow_hash_href docker volume rm sdk-html diff --git a/website/config.toml b/website/config.toml index f9bddbf7eb5..e17dc805cef 100644 --- a/website/config.toml +++ b/website/config.toml @@ -78,12 +78,19 @@ github_repo = "https://github.com/operator-framework/operator-sdk" [[params.versions]] version = "master" - url = "/docs" + url = "https://master.sdk.operatorframework.io" [[params.versions]] - version = "v0.16" - url = "https://github.com/operator-framework/operator-sdk/tree/v0.16.x/doc" + version = "Latest Release" + url = "https://sdk.operatorframework.io" +[[params.versions]] + version = "v0.18" + url = "https://v0-18-x.sdk.operatorframework.io" + +[[params.versions]] + version = "v0.17" + url = "https://github.com/operator-framework/operator-sdk/tree/v0.17.x/doc" # Specify a value here if your content directory is not in your repo's root directory github_subdir = "website" diff --git a/website/layouts/partials/navbar-version-selector.html b/website/layouts/partials/navbar-version-selector.html new file mode 100644 index 00000000000..5a20b86221d --- /dev/null +++ b/website/layouts/partials/navbar-version-selector.html @@ -0,0 +1,8 @@ + + diff --git a/website/layouts/partials/navbar.html b/website/layouts/partials/navbar.html index bedccadd56e..5e3ef3d846d 100644 --- a/website/layouts/partials/navbar.html +++ b/website/layouts/partials/navbar.html @@ -2,20 +2,24 @@ - - + + - - \ No newline at end of file +