fix: improved headers.txt #117
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: Build and Deploy ExampleSite to GitHub Pages | |
| on: | |
| push: | |
| branches: | |
| - gh-pages | |
| permissions: | |
| contents: read | |
| pages: write | |
| id-token: write | |
| concurrency: | |
| group: "pages" | |
| cancel-in-progress: false | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod | |
| - name: Setup Hugo | |
| uses: peaceiris/actions-hugo@v3 | |
| with: | |
| hugo-version: '0.128.0' | |
| extended: true | |
| - name: Cache Hugo modules | |
| uses: actions/cache@v4 | |
| with: | |
| path: | | |
| ~/.cache/hugo | |
| exampleSite/resources | |
| exampleSite/.hugo_build.lock | |
| key: ${{ runner.os }}-hugomod-${{ hashFiles('**/go.mod', '**/go.sum') }} | |
| restore-keys: | | |
| ${{ runner.os }}-hugomod- | |
| - name: Clean and Setup | |
| run: | | |
| rm -rf exampleSite/public/ | |
| rm -rf exampleSite/resources/ | |
| rm -rf exampleSite/.hugo_build.lock | |
| - name: Install Hugo modules and vendor theme | |
| run: | | |
| cd exampleSite | |
| hugo mod get -u | |
| hugo mod tidy | |
| hugo mod vendor | |
| - name: Build example site | |
| env: | |
| HUGO_ENVIRONMENT: production | |
| HUGO_ENV: production | |
| run: | | |
| cd exampleSite | |
| hugo \ | |
| --minify \ | |
| --cleanDestinationDir \ | |
| --baseURL "https://stradichenko.github.io/PKB-theme/" \ | |
| --environment production \ | |
| --logLevel debug | |
| - name: Upload artifact | |
| uses: actions/upload-pages-artifact@v3 | |
| with: | |
| path: exampleSite/public | |
| deploy: | |
| needs: build | |
| runs-on: ubuntu-latest | |
| environment: | |
| name: github-pages | |
| url: ${{ steps.deployment.outputs.page_url }} | |
| steps: | |
| - name: Deploy to GitHub Pages | |
| id: deployment | |
| uses: actions/deploy-pages@v4 |