Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 8 additions & 7 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ jobs:
~/.cargo/git
~/.cargo/bin
wasm/target
key: ${{ runner.os }}-cargo-${{ hashFiles('wasm/Cargo.toml', 'app/package-lock.json') }}
key: ${{ runner.os }}-cargo-${{ hashFiles('wasm/Cargo.toml', 'app/yarn.lock') }}

- name: Install wasm-pack
run: curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh
Expand All @@ -45,21 +45,22 @@ jobs:
with:
node-version: 22

# `npm install` pulls `comline-simulator` (the sim engine) as a git
# dependency and builds its WASM in `prepare` — lean `pkg/` + scripted
# `yarn install` pulls `comline-simulator` (the sim engine) as a git
# dependency and builds its WASM in `prepack` — lean `pkg/` + scripted
# `pkg-script/`. The runner has cargo + wasm-opt; the cargo cache above
# keeps the one-time wasm-bindgen-cli build.
# keeps the one-time wasm-bindgen-cli build. Yarn is the runner's 1.x,
# which delegates to the committed `.yarn/releases/` (Yarn 4).
- name: Install
working-directory: app
run: npm install
run: yarn install

- name: Test (simulate view)
working-directory: app
run: npm test
run: yarn test

- name: Build site
working-directory: app
run: npm run build
run: yarn build

- uses: actions/upload-pages-artifact@v3
with:
Expand Down
13 changes: 11 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,13 +1,22 @@
# Rust — the editor wasm crate (the sim engine is an npm git dependency now)
# Rust — the editor wasm crate (the sim engine is a git dependency now)
/wasm/target
Cargo.lock

# Node / Vite
node_modules
/app/dist

# wasm-pack output for the editor wasm (regenerated by `npm run wasm` / CI)
# wasm-pack output for the editor wasm (regenerated by `yarn wasm` / CI)
/app/src/wasm

# Yarn Berry (app/) — keep the pinned release, drop the rest
/app/.yarn/*
!/app/.yarn/patches
!/app/.yarn/plugins
!/app/.yarn/releases
!/app/.yarn/sdks
!/app/.yarn/versions
/app/.pnp.*

.DS_Store
.idea/
1,000 changes: 1,000 additions & 0 deletions app/.yarn/releases/yarn-4.18.0.cjs

Large diffs are not rendered by default.

14 changes: 14 additions & 0 deletions app/.yarnrc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
yarnPath: .yarn/releases/yarn-4.18.0.cjs
nodeLinker: node-modules

# `comline-simulator` is the sim engine — fetched from git and built to WASM in
# its `prepack`/`prepare` on install. Yarn 4 gates git deps behind this
# allow-list and disables lifecycle scripts by default; the build needs both on.
approvedGitRepositories:
- "https://github.com/ComlineProject/simulator.git"
enableScripts: true

# That WASM build isn't byte-reproducible (wasm-opt runs only where it's
# installed), so the git dep's tarball checksum drifts between machines — let
# Yarn refresh it instead of failing the install.
checksumBehavior: update
Loading
Loading