/ concept-collection / turing-sphere
Sign in
concept-collection / turing-sphere
57 lines · 1.9 KBBlameHistoryRaw
1name: deploy
2on:
3 push:
4 branches: [main]
5 workflow_dispatch:
7permissions:
8 contents: read
9 pages: write
10 id-token: write
12concurrency:
13 group: pages
14 cancel-in-progress: true
16jobs:
17 build-deploy:
18 runs-on: ubuntu-latest
19 environment:
20 name: github-pages
21 url: ${{ steps.deployment.outputs.page_url }}
22 steps:
23 - uses: actions/checkout@v4
24 - uses: actions/setup-node@v4
25 with:
26 node-version: 24
27 cache: npm
28 # numbl is a `file:../../numbl` dependency: we use its compiler internals
29 # (parser, lowerer, IR, inline pass), which its published package `exports`
30 # do not expose. Clone it where that relative path expects it. Pinned so a
31 # change to those internals cannot silently break the build — the surface we
32 # rely on is written down in src/mgpu/numbl.d.ts.
33 #
34 # numbl's own dependencies are NOT needed: the slice we import is
35 # self-contained TypeScript, verified by building against a checkout with no
36 # node_modules.
37 - name: Check out numbl (sibling dependency)
38 env:
39 NUMBL_REF: 38ce14046d64d03ecf05cb57def53057a6bc64ab
40 run: |
41 git clone --filter=blob:none --no-checkout \
42 https://github.com/flatironinstitute/numbl.git "$GITHUB_WORKSPACE/../../numbl"
43 git -C "$GITHUB_WORKSPACE/../../numbl" checkout --quiet "$NUMBL_REF"
44 # --ignore-scripts: npm runs a linked package's `prepare` script, and
45 # numbl's is husky, which is not installed here.
46 - run: npm ci --ignore-scripts
47 - run: npm run test:node
48 - run: npm run build
49 - uses: actions/configure-pages@v5
50 # turn Pages on for a fresh repo without a manual visit to Settings
51 with:
52 enablement: true
53 - uses: actions/upload-pages-artifact@v3
54 with:
55 path: dist
56 - id: deployment
57 uses: actions/deploy-pages@v4
moveopenescclose