Fix up Go version and upgrade actions #264
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: Publish docs | |
on: | |
workflow_dispatch: | |
push: | |
branches: [main] | |
release: | |
types: [released] | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Install Bun | |
uses: oven-sh/setup-bun@v2 | |
with: | |
bun-version: latest | |
- name: Install dependencies | |
run: bun install | |
- name: Build site | |
run: bun run docs:build | |
- name: Generate Netlify redirects file | |
run: python scripts/generate-redirects.py | |
- name: Publish to Cloudflare Pages | |
id: cloudflare-publish | |
uses: cloudflare/pages-action@v1 | |
with: | |
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }} | |
accountId: 8e782a355544971b192db9e75d789dca | |
projectName: 9koctober | |
directory: .vitepress/dist | |
gitHubToken: ${{ secrets.GITHUB_TOKEN }} | |
- uses: mshick/add-pr-comment@v2 | |
with: | |
message: | | |
🚀 This branch can be previewed at ${{ steps.cloudflare-publish.outputs.url }} |