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:
17
17
group : " pages"
18
18
cancel-in-progress : false
19
19
20
+ # Default to bash
21
+ defaults :
22
+ run :
23
+ shell : bash
24
+
20
25
jobs :
21
26
build :
22
27
runs-on : ubuntu-latest
28
+ env :
29
+ HUGO_VERSION : 0.121.0
23
30
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
+
24
36
- name : Checkout
25
37
uses : actions/checkout@v4
26
38
with :
@@ -36,14 +48,19 @@ jobs:
36
48
run : npm install
37
49
working-directory : ${{ github.workspace }}
38
50
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
44
54
45
55
- 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 }}/"
47
64
working-directory : ${{ github.workspace }}
48
65
49
66
- name : Upload artifact
You can’t perform that action at this time.
0 commit comments