mirror of
https://github.com/imfing/hextra.git
synced 2025-05-13 18:46:25 -04:00
build(ci): build doc site from latest release instead of main
- bump hugo version in workflow - bump github actions deps versions - minor update to head.html to remove empty spaces
This commit is contained in:
parent
ff85e6951d
commit
4c4f43779c
15
.github/workflows/pages.yml
vendored
15
.github/workflows/pages.yml
vendored
@ -31,7 +31,7 @@ jobs:
|
|||||||
build:
|
build:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
env:
|
env:
|
||||||
HUGO_VERSION: 0.131.0
|
HUGO_VERSION: 0.136.5
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
@ -41,10 +41,10 @@ jobs:
|
|||||||
- name: Setup Go
|
- name: Setup Go
|
||||||
uses: actions/setup-go@v5
|
uses: actions/setup-go@v5
|
||||||
with:
|
with:
|
||||||
go-version: '1.22'
|
go-version: '1.23'
|
||||||
- name: Setup Pages
|
- name: Setup Pages
|
||||||
id: pages
|
id: pages
|
||||||
uses: actions/configure-pages@v4
|
uses: actions/configure-pages@v5
|
||||||
- name: Setup Hugo
|
- name: Setup Hugo
|
||||||
run: |
|
run: |
|
||||||
wget -O ${{ runner.temp }}/hugo.deb https://github.com/gohugoio/hugo/releases/download/v${HUGO_VERSION}/hugo_extended_${HUGO_VERSION}_linux-amd64.deb \
|
wget -O ${{ runner.temp }}/hugo.deb https://github.com/gohugoio/hugo/releases/download/v${HUGO_VERSION}/hugo_extended_${HUGO_VERSION}_linux-amd64.deb \
|
||||||
@ -54,11 +54,12 @@ jobs:
|
|||||||
# For maximum backward compatibility with Hugo modules
|
# For maximum backward compatibility with Hugo modules
|
||||||
HUGO_ENVIRONMENT: production
|
HUGO_ENVIRONMENT: production
|
||||||
HUGO_ENV: production
|
HUGO_ENV: production
|
||||||
|
# Use the latest release of the theme to build exampleSite
|
||||||
run: |
|
run: |
|
||||||
hugo \
|
cd exampleSite && rm go.mod
|
||||||
--minify \
|
hugo mod init github.com/imfing/hextra/exampleSite
|
||||||
--themesDir=../.. --source=exampleSite \
|
hugo mod get -u github.com/imfing/hextra
|
||||||
--baseURL "${{ steps.pages.outputs.base_url }}/"
|
hugo --minify --baseURL "${{ steps.pages.outputs.base_url }}/"
|
||||||
- name: Upload artifact
|
- name: Upload artifact
|
||||||
uses: actions/upload-pages-artifact@v3
|
uses: actions/upload-pages-artifact@v3
|
||||||
with:
|
with:
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
{{ else -}}
|
{{ else -}}
|
||||||
<meta name="robots" content="noindex, nofollow" />
|
<meta name="robots" content="noindex, nofollow" />
|
||||||
{{ end -}}
|
{{ end -}}
|
||||||
{{ partialCached "favicons.html" . }}
|
{{ partialCached "favicons.html" . -}}
|
||||||
<title>
|
<title>
|
||||||
{{- if .IsHome -}}
|
{{- if .IsHome -}}
|
||||||
{{ .Site.Title -}}
|
{{ .Site.Title -}}
|
||||||
@ -17,17 +17,17 @@
|
|||||||
</title>
|
</title>
|
||||||
<meta name="description" content="{{ partial "utils/page-description.html" . }}" />
|
<meta name="description" content="{{ partial "utils/page-description.html" . }}" />
|
||||||
|
|
||||||
{{ with .Params.canonical }}
|
{{- with .Params.canonical -}}
|
||||||
<link rel="canonical" href="{{ . }}" itemprop="url" />
|
<link rel="canonical" href="{{ . }}" itemprop="url" />
|
||||||
{{ else }}
|
{{- else -}}
|
||||||
<link rel="canonical" href="{{ .Permalink }}" itemprop="url" />
|
<link rel="canonical" href="{{ .Permalink }}" itemprop="url" />
|
||||||
{{ end }}
|
{{- end -}}
|
||||||
|
|
||||||
{{ partial "opengraph.html" . }}
|
{{- partial "opengraph.html" . -}}
|
||||||
{{ template "_internal/schema.html" . -}}
|
{{- template "_internal/schema.html" . -}}
|
||||||
{{ template "_internal/twitter_cards.html" . -}}
|
{{- template "_internal/twitter_cards.html" . -}}
|
||||||
|
|
||||||
{{ partialCached "head-css.html" . }}
|
{{- partialCached "head-css.html" . -}}
|
||||||
|
|
||||||
|
|
||||||
<!-- Google Analytics -->
|
<!-- Google Analytics -->
|
||||||
|
Loading…
x
Reference in New Issue
Block a user