From 013d9ed1aef130bac671c723f4e772b899cd5de9 Mon Sep 17 00:00:00 2001 From: JP Hastings-Spital Date: Wed, 2 Aug 2023 18:11:33 +0100 Subject: [PATCH] Cache retrieved files --- .github/workflows/publish.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index aff23589..39da63ce 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -36,6 +36,13 @@ jobs: - name: Setup Pages id: pages uses: actions/configure-pages@v2 + - name: Cache Hugo persistent info + uses: actions/cache@v3 + env: + cache-name: hugo-persistent-cache + with: + path: /tmp/hugo + key: ${{ env.cache-name }} - name: Build with Hugo env: # For maximum backward compatibility with Hugo modules @@ -43,6 +50,7 @@ jobs: HUGO_ENV: production run: | hugo \ + --cacheDir /tmp/hugo/cache \ --minify # Don't force a base URL, so relative links work everywhere # --baseURL "${{ steps.pages.outputs.base_url }}/"