Skip to content

Commit

Permalink
Fix auto-updated release version
Browse files Browse the repository at this point in the history
  • Loading branch information
jonathan-innis committed Mar 2, 2024
1 parent 67fb5ae commit b827ee9
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion hack/release/common.sh
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ removeOldWebsiteDirectories() {
editWebsiteConfig() {
local version="${1}"

yq -i ".params.latest_release_version = \"v${version}\"" website/hugo.yaml
yq -i ".params.latest_release_version = \"${version}\"" website/hugo.yaml
}

# editWebsiteVersionsMenu sets relevant releases in the version dropdown menu of the website
Expand Down
2 changes: 1 addition & 1 deletion website/hugo.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ params:
url: "https://slack.k8s.io/"
icon: fab fa-slack
desc: "Chat with us on Slack in the #aws-provider channel"
latest_release_version: v0.35.0
latest_release_version: 0.35.0
latest_k8s_version: 1.29
versions:
- v0.35
Expand Down
2 changes: 1 addition & 1 deletion website/layouts/partials/navbar-version-selector.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{{ $pageDir := index (split (path.Dir .Page.RelPermalink) "/") 1 }}
<!-- special treatment for the homepage. we treat it same as latest docs //-->
{{ if or (eq $pageDir "docs") (eq $pageDir "") }}
{{ $pageDir = printf "%s.%s" ( index ( split .Site.Params.latest_release_version "." ) 0 ) ( index ( split .Site.Params.latest_release_version "." ) 1 ) }}
{{ $pageDir = printf "v%s.%s" ( index ( split .Site.Params.latest_release_version "." ) 0 ) ( index ( split .Site.Params.latest_release_version "." ) 1 ) }}
{{ end }}
{{ $pagePath := replace .Page.RelPermalink "docs" "" }}
{{ $pagePath = replace $pagePath $pageDir "" }}
Expand Down

0 comments on commit b827ee9

Please sign in to comment.