From 9af021f8bd0dadc561f96c2ca5cadaf373fdc4b9 Mon Sep 17 00:00:00 2001 From: Arisu Tachibana Date: Mon, 31 Mar 2025 13:02:36 +0900 Subject: [PATCH] hugo: Add version changer Signed-off-by: Arisu Tachibana --- .github/workflows/docs.yml | 5 +++++ hugo.toml | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index e40374d..f2ffc14 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -52,6 +52,7 @@ jobs: git clone --recursive --depth 1 --branch master https://github.com/adityatelange/hugo-PaperMod.git themes/PaperMod git clone --depth 1 --branch 6.7.0 https://github.com/FortAwesome/Font-Awesome.git themes/github.com/FortAwesome/Font-Awesome git clone --depth 1 --branch v5.3.3 https://github.com/twbs/bootstrap.git themes/github.com/twbs/bootstrap + sed -i 's/{version}//' hugo.toml hugo \ --gc \ --theme PaperMod \ @@ -63,10 +64,12 @@ jobs: HUGO_ENVIRONMENT: production TZ: America/Los_Angeles run: | + git checkout hugo.toml git fetch --prune --unshallow git fetch --depth=1 origin +refs/tags/*:refs/tags/* git fetch --all --tags git checkout tags/v0.1.4 + sed -i 's/{version}/v0.1.4/' hugo.toml hugo \ --gc \ --theme PaperMod \ @@ -79,10 +82,12 @@ jobs: HUGO_ENVIRONMENT: production TZ: America/Los_Angeles run: | + git checkout hugo.toml git fetch --prune --unshallow git fetch --depth=1 origin +refs/tags/*:refs/tags/* git fetch --all --tags git checkout tags/v0.1.3 + sed -i 's/{version}/v0.1.3/' hugo.toml hugo \ --gc \ --theme PaperMod \ diff --git a/hugo.toml b/hugo.toml index 5e21304..029561d 100644 --- a/hugo.toml +++ b/hugo.toml @@ -1,4 +1,4 @@ -baseURL = 'https://kci.dev/' +baseURL = 'https://kci.dev/{version}' languageCode = 'en-us' title = 'kci-dev' description = 'Stand alone tool for Linux Kernel developers and maintainers to interact with KernelCI'