File tree Expand file tree Collapse file tree 1 file changed +23
-6
lines changed Expand file tree Collapse file tree 1 file changed +23
-6
lines changed Original file line number Diff line number Diff line change @@ -17,10 +17,22 @@ concurrency:
1717 group : " pages"
1818 cancel-in-progress : false
1919
20+ # Default to bash
21+ defaults :
22+ run :
23+ shell : bash
24+
2025jobs :
2126 build :
2227 runs-on : ubuntu-latest
28+ env :
29+ HUGO_VERSION : 0.121.0
2330 steps :
31+ - name : Install Hugo CLI
32+ run : |
33+ wget -O ${{ runner.temp }}/hugo.deb https://github.com/gohugoio/hugo/releases/download/v${HUGO_VERSION}/hugo_extended_${HUGO_VERSION}_linux-amd64.deb \
34+ && sudo dpkg -i ${{ runner.temp }}/hugo.deb
35+
2436 - name : Checkout
2537 uses : actions/checkout@v4
2638 with :
@@ -36,14 +48,19 @@ jobs:
3648 run : npm install
3749 working-directory : ${{ github.workspace }}
3850
39- - name : Setup Hugo
40- uses : peaceiris/actions-hugo@v2
41- with :
42- hugo-version : ' latest'
43- extended : true
51+ - name : Setup Pages
52+ id : pages
53+ uses : actions/configure-pages@v4
4454
4555 - name : Build with Hugo
46- run : hugo --minify
56+ env :
57+ HUGO_ENVIRONMENT : production
58+ HUGO_ENV : production
59+ run : |
60+ hugo \
61+ --gc \
62+ --minify \
63+ --baseURL "${{ steps.pages.outputs.base_url }}/"
4764 working-directory : ${{ github.workspace }}
4865
4966 - name : Upload artifact
You can’t perform that action at this time.
0 commit comments