formatting #17
This file contains 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 Deployment | |
on: | |
push: | |
branches: | |
- main # Triggers the workflow on pushes to the main branch | |
jobs: | |
build-deploy: | |
runs-on: ubuntu-latest # Use GitHub-hosted runner | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@v3 | |
with: | |
submodules: true # Include if using submodules | |
- name: Setup Hugo | |
uses: peaceiris/actions-hugo@v2 | |
with: | |
hugo-version: 'latest' # Specify Hugo version | |
extended: false # Set to true if using extended features | |
- name: Build Site | |
run: hugo --minify | |
- name: Deploy to GitHub Pages | |
uses: peaceiris/actions-gh-pages@v4 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: ./public | |
publish_branch: gh-pages | |