Use extended version for SASS #3
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: GitHub Pages | |
| on: | |
| push: | |
| branches: | |
| - master # Set a branch to deploy | |
| pull_request: | |
| jobs: | |
| deploy: | |
| runs-on: ubuntu-22.04 | |
| env: | |
| HUGO_CACHEDIR: /tmp/hugo_cache # <- Define the env variable here, so that Hugo's cache dir is now predictible in your workflow and doesn't depend on the Hugo's version you're using. | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| submodules: true # Fetch Hugo themes (true OR recursive) | |
| fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod | |
| - name: Setup Hugo | |
| uses: peaceiris/actions-hugo@v3 | |
| with: | |
| hugo-version: '0.147.9' | |
| extended: true | |
| - uses: actions/cache@v4 | |
| with: | |
| path: ${{ env.HUGO_CACHEDIR }} # <- Use the same env variable just right here | |
| key: ${{ runner.os }}-hugomod-${{ hashFiles('**/go.sum') }} | |
| restore-keys: ${{ runner.os }}-hugomod- | |
| - name: Build | |
| working-directory: ./docs | |
| run: hugo --minify | |
| - name: Deploy | |
| uses: peaceiris/actions-gh-pages@v3 | |
| if: github.ref == 'refs/heads/main' | |
| with: | |
| github_token: ${{ secrets.GITHUB_TOKEN }} | |
| publish_dir: ./docs/public |