mirror of
https://github.com/peaceiris/actions-hugo.git
synced 2025-06-18 10:05:28 +08:00
Compare commits
1 Commits
c72e3ae9fd
...
92d4aa8858
Author | SHA1 | Date | |
---|---|---|---|
![]() |
92d4aa8858 |
@ -154,15 +154,9 @@ Insert a cache step before site-building as follows.
|
|||||||
Note that with latest hugo version, the [cache dir location](https://gohugo.io/getting-started/configuration/#configure-cachedir) on a Linux-based operating system is `${HOME}/.cache`. On macOS, `${HOME}/Library/Caches` has the location.
|
Note that with latest hugo version, the [cache dir location](https://gohugo.io/getting-started/configuration/#configure-cachedir) on a Linux-based operating system is `${HOME}/.cache`. On macOS, `${HOME}/Library/Caches` has the location.
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
- name: Setup Go
|
|
||||||
uses: actions/setup-go@v5
|
|
||||||
with:
|
|
||||||
go-version: 'stable'
|
|
||||||
|
|
||||||
- uses: actions/cache@v3
|
- uses: actions/cache@v3
|
||||||
with:
|
with:
|
||||||
path: /home/runner/.cache/hugo_cache # <-- with hugo version v0.116.0 and above
|
path: /tmp/hugo_cache_runner # <-- with hugo version v0.116.0 and above
|
||||||
# path: /tmp/hugo_cache_runner # <-- with hugo version v0.116.0 and above, and without actions/setup-go step.
|
|
||||||
# path: /tmp/hugo_cache # <-- with hugo version < v0.116.0
|
# path: /tmp/hugo_cache # <-- with hugo version < v0.116.0
|
||||||
key: ${{ runner.os }}-hugomod-${{ hashFiles('**/go.sum') }}
|
key: ${{ runner.os }}-hugomod-${{ hashFiles('**/go.sum') }}
|
||||||
restore-keys: |
|
restore-keys: |
|
||||||
|
Loading…
Reference in New Issue
Block a user