A JSpecify taglet for use in conformance tests #697
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: Docs | |
on: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: | |
- main | |
jobs: | |
# Runs on PRs and push to ensure the documentation successfully builds. | |
build: | |
name: Build Documentation | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: 18 | |
- name: Install Dependencies | |
run: npm install | |
working-directory: docs | |
- name: Build Documentation | |
run: npm run build | |
working-directory: docs | |
- uses: actions/upload-artifact@v4 | |
with: | |
name: document | |
path: docs/build | |
# Deploys the documentation if this is a push to the main branch. | |
deploy: | |
name: Deploy Documentation | |
if: github.event_name == 'push' && github.ref == 'refs/heads/main' | |
needs: build | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/download-artifact@v4 | |
with: | |
name: document | |
path: docs/build | |
- uses: JamesIves/github-pages-deploy-action@v4.6.1 | |
with: | |
branch: gh-pages | |
folder: docs/build |