Files
house-of-vanity.github.io/.github/workflows/build-and-publish.yaml
Alexandr Bogomyakov 2b891b52f4
Some checks failed
Build and deploy GH Pages / build (push) Has been cancelled
Fix
2024-10-04 03:42:08 +03:00

24 lines
669 B
YAML

# On every push this script is executed
on: push
name: Build and deploy GH Pages
jobs:
build:
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/zola'
steps:
- name: Checkout
uses: actions/checkout@v3.0.0
- name: Set outputs
id: vars
run: echo "sha_short=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT
- name: Set commit id
run: sed -e "s/tag\ =.*/tag = \"${{ steps.vars.outputs.sha_short }}\"/" -i config.toml
- name: Build and push to gh-pages branch
uses: shalzz/zola-deploy-action@v0.17.2
env:
PAGES_BRANCH: gh-pages
TOKEN: ${{ secrets.GITHUB_TOKEN }}