Skip to content

Commit

Permalink
Build on GitHub Actions
Browse files Browse the repository at this point in the history
  • Loading branch information
Novakov committed Sep 26, 2024
1 parent c122ee4 commit 01ec395
Showing 1 changed file with 31 additions and 0 deletions.
31 changes: 31 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Build and publish documentation
on: push
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Install pipx
run: sudo apt-get install -y pipx
- name: Install hatch
run: pipx install hatch==1.9.4
- uses: actions/checkout@v3
- name: Build documentation
run: hatch run dev:build
- uses: actions/upload-pages-artifact@v3
with:
path: build/html
deploy: # https://github.com/actions/deploy-pages
needs: build
if: github.ref == format('refs/heads/{0}', 'github-deploy') #github.event.repository.default_branch)
# Grant GITHUB_TOKEN the permissions required to make a Pages deployment
permissions:
pages: write # to deploy to Pages
id-token: write # to verify the deployment originates from an appropriate source
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4

0 comments on commit 01ec395

Please sign in to comment.