From 20a0cb88d660bcc9bee1b5b90fc903765bcf02c6 Mon Sep 17 00:00:00 2001 From: Alex Rowley Date: Thu, 28 Dec 2017 21:16:10 +0000 Subject: [PATCH] Add conditional for versioned url (#6712) Checks an additional variable named versionedurl for the version name, and uses the value as the url to reference. If the versionedurl doesn't contain an entry for the version the current path is used. e.g. versionedurl: v1.8: /docs/home v1.7: /docs/old-path-to-doc --- _config.yml | 10 +++++----- _includes/header.html | 6 +++++- 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/_config.yml b/_config.yml index d601fa4f51..3471320708 100644 --- a/_config.yml +++ b/_config.yml @@ -27,27 +27,27 @@ defaults: version: "v1.9" githubbranch: "v1.9.0" docsbranch: "release-1.9" - url: https://kubernetes.io/docs/home/ + url: https://kubernetes.io - fullversion: "v1.8.4" version: "v1.8" githubbranch: "v1.8.4" docsbranch: "release-1.8" - url: https://v1-8.docs.kubernetes.io/docs/home/ + url: https://v1-8.docs.kubernetes.io - fullversion: "v1.7.6" version: "v1.7" githubbranch: "v1.7.6" docsbranch: "release-1.7" - url: https://v1-7.docs.kubernetes.io/docs/home/ + url: https://v1-7.docs.kubernetes.io - fullversion: "v1.6.8" version: "v1.6" githubbranch: "v1.6.8" docsbranch: "release-1.6" - url: https://v1-6.docs.kubernetes.io/docs/home/ + url: https://v1-6.docs.kubernetes.io - fullversion: "v1.5.7" version: "v1.5" githubbranch: "v1.5.7" docsbranch: "release-1.5" - url: https://v1-5.docs.kubernetes.io/docs/ + url: https://v1-5.docs.kubernetes.io deprecated: false currentUrl: https://kubernetes.io/docs/home/ nextUrl: http://kubernetes-io-vnext-staging.netlify.com/ diff --git a/_includes/header.html b/_includes/header.html index a4c5250282..8db73df89d 100644 --- a/_includes/header.html +++ b/_includes/header.html @@ -16,7 +16,11 @@