Prebuild S2N (#584) #144
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
# Update the API documentation whenever the `main` branch changes. | |
# This documentation lives in its own `docs` branch. | |
name: docs | |
on: | |
push: | |
branches: | |
- 'main' | |
jobs: | |
update-docs-branch: | |
runs-on: ubuntu-20.04 # latest | |
permissions: | |
contents: write # allow push | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
submodules: true | |
- name: Update docs branch | |
run: | | |
npm ci | |
./make-docs.sh | |
- name: Commit | |
run: | | |
git config --local user.email "[email protected]" | |
git config --local user.name "GitHub Action" | |
git add --force docs/ | |
git commit --message="update docs" | |
- name: Push to docs branch | |
uses: ad-m/[email protected] | |
with: | |
github_token: ${{ github.token }} | |
branch: docs | |
# Force push so that `docs` branch always looks like `main`, | |
# but with 1 additional "update docs" commit. | |
# This seems simpler than trying to cleanly merge `main` into | |
# `docs` each time. | |
force: true |