Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deploy to GitHub Pages directly via Action #1555

Merged
merged 1 commit into from
Jul 15, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 18 additions & 5 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,9 +56,22 @@ jobs:
echo "Zola version: $(./zola --version)"
- name: Zola build
run: ./zola build
- name: Deploy
if: github.ref == 'refs/heads/source'
uses: crazy-max/ghaction-github-pages@v1
- name: Upload GitHub Pages artifact
uses: actions/upload-pages-artifact@v1
with:
build_dir: public
target_branch: master
path: public

pages:
needs: zola
permissions:
pages: write
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
if: format('refs/heads/{0}', github.event.repository.default_branch) == github.ref
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
Loading