Fix the sorting order #10
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: Zola on GitHub Pages | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
if: github.ref != 'refs/heads/master' | |
steps: | |
- name: Checkout main | |
uses: actions/checkout@v3.0.0 | |
- name: Build only | |
uses: shalzz/zola-deploy-action@v0.17.2 | |
env: | |
BUILD_DIR: . | |
BUILD_ONLY: true | |
BUILD_FLAGS: --drafts | |
# A GitHub token is not necessary when BUILD_ONLY is true | |
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
build_and_deploy: | |
runs-on: ubuntu-latest | |
if: github.ref == 'refs/heads/master' | |
steps: | |
- name: Checkout main | |
uses: actions/checkout@v3.0.0 | |
- name: Build and deploy | |
uses: shalzz/zola-deploy-action@v0.17.2 | |
env: | |
BUILD_DIR: . | |
PAGES_BRANCH: gh-pages | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |