diff --git a/generator/build/install_hugo.sh b/generator/build/install_hugo.sh index f223a3aab..b9e0ebc13 100644 --- a/generator/build/install_hugo.sh +++ b/generator/build/install_hugo.sh @@ -1,7 +1,11 @@ #!/bin/bash -wget -nv https://github.com/gohugoio/hugo/releases/download/v0.168.0/hugo_0.168.0_Linux-64bit.tar.gz -O hugo.tar.gz - echo "fada83ad56bb27ed4cb7dd81590303bdac16140f944ac4e66fc248117e2d5594 hugo.tar.gz" | sha256sum -c +# go and git are needed by Hugo to download modules (llms-txt) +sudo apt-get install -y -qq golang-1.26-go git +sudo ln -sf /usr/lib/go-1.26/bin/go /usr/local/bin/go + +wget -nv https://github.com/gohugoio/hugo/releases/download/v0.167.0/hugo_0.167.0_Linux-64bit.tar.gz -O hugo.tar.gz + echo "4d84519b9f619e6d4c3fb45a50157abeabeb724f859c60605f44c23def6e1169 hugo.tar.gz" | sha256sum -c if [ $? -eq 1 ]; then exit 2 fi diff --git a/hugo/config.toml b/hugo/config.toml index 2ea1c3c87..4993b3550 100644 --- a/hugo/config.toml +++ b/hugo/config.toml @@ -15,6 +15,8 @@ repositoryUrl = "https://github.com/cfengine/documentation" searchBaseUrl = "/docs/search/%branch%/" searchUrlPrefix = ".." domain = "docs.cfengine.com" +# Used as the summary line in llms.txt +description = "CFEngine %branch% documentation: installation, policy language reference, Masterfiles Policy Framework, Mission Portal and Enterprise API." isLTS = false [params.cfengine] @@ -56,3 +58,21 @@ baseUrl = "https://docs.cfengine.com/docs/%branch%" secondary = "#f5821f" link = "#1d71d3" footer = "#052569" + +# llms.txt (https://llmstxt.org), see +# https://github.com/gethugothemes/hugo-modules/tree/main/llms-txt +# go.mod / go.sum come from nt-docs +[module] +[[module.imports]] +path = "github.com/gethugothemes/hugo-modules/llms-txt" + +[outputs] +home = ["HTML", "RSS", "llms", "llmsfull", "md"] +section = ["HTML", "RSS", "md"] +page = ["HTML", "md"] + +[params.llms] +generate_llms_txt = true +generate_llms_full_txt = true +include = [] +exclude = ["/tags/**"]