Removes every comment introduced on this branch: website/ in full, pages.yml in full, and only the blocks added to ci.yml and release.yml — their pre-existing comments are untouched. Two directives survive because they are load-bearing rather than prose: the triple-slash vite/client reference, and nothing else. Two comments were carrying behaviour that the code did not state, so the code now states it. useCopy's rejection handler clears the copied flag instead of sitting empty, and writeTheme returns whether the write actually landed instead of swallowing the failure in a bare catch. isExternal drops its regex for two startsWith calls, which reads the same and no longer hides a `//` inside a literal.
64 lines
1.3 KiB
YAML
64 lines
1.3 KiB
YAML
name: Pages
|
|
|
|
on:
|
|
push:
|
|
branches: [master]
|
|
paths: ['website/**', '.github/workflows/pages.yml']
|
|
pull_request:
|
|
branches: ['**']
|
|
paths: ['website/**', '.github/workflows/pages.yml']
|
|
workflow_dispatch:
|
|
|
|
permissions:
|
|
contents: read
|
|
|
|
jobs:
|
|
build:
|
|
name: Build
|
|
runs-on: ubuntu-latest
|
|
timeout-minutes: 10
|
|
defaults:
|
|
run:
|
|
working-directory: website
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- uses: oven-sh/setup-bun@v2
|
|
with:
|
|
bun-version: latest
|
|
|
|
- name: Install
|
|
run: bun install --frozen-lockfile
|
|
|
|
- name: Typecheck
|
|
run: bun run typecheck
|
|
|
|
- name: Lint
|
|
run: bun run lint
|
|
|
|
- name: Build
|
|
run: bun run build
|
|
|
|
- uses: actions/upload-pages-artifact@v3
|
|
with:
|
|
path: website/dist
|
|
|
|
deploy:
|
|
name: Deploy
|
|
if: github.ref == 'refs/heads/master' && github.event_name != 'pull_request'
|
|
needs: build
|
|
runs-on: ubuntu-latest
|
|
timeout-minutes: 10
|
|
concurrency:
|
|
group: pages
|
|
cancel-in-progress: false
|
|
permissions:
|
|
pages: write
|
|
id-token: write
|
|
environment:
|
|
name: github-pages
|
|
url: ${{ steps.deployment.outputs.page_url }}
|
|
steps:
|
|
- id: deployment
|
|
uses: actions/deploy-pages@v4
|