From d7773a0aa4b62978dc9cff224763776db8406469 Mon Sep 17 00:00:00 2001 From: "Bryan A. Jones" Date: Sat, 31 Oct 2026 15:37:13 -0500 Subject: [PATCH 1/7] Fix: Update to pnpm 12. https://github.com/pnpm/pnpm/issues/3027 is closed. --- builder/src/main.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/builder/src/main.rs b/builder/src/main.rs index f0f6f1a6..75523635 100644 --- a/builder/src/main.rs +++ b/builder/src/main.rs @@ -384,7 +384,7 @@ fn patch_client_libs() -> io::Result<()> { fn run_install(dev: bool) -> io::Result<()> { if dev { - run_script("npm", &["install", "-g", "pnpm@latest-11"], ".", true)?; + run_script("npm", &["install", "-g", "pnpm"], ".", true)?; } // See [the client manifest](../../client/package.json5) for an explanation // of `--no-frozen-lockfile`. From af6afa7c67df2f530dbfd861b277939ad715cce2 Mon Sep 17 00:00:00 2001 From: "Bryan A. Jones" Date: Sat, 31 Oct 2026 16:30:24 -0500 Subject: [PATCH 2/7] Clean: rename variable to clarify use. --- server/src/processing/cache.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/server/src/processing/cache.rs b/server/src/processing/cache.rs index 4aaa1aba..d0b6fce8 100644 --- a/server/src/processing/cache.rs +++ b/server/src/processing/cache.rs @@ -1825,7 +1825,7 @@ fn scan_file( ) { // Perform I/O before locking the cache, so that the lock isn't held during // it. - let stamp = match fs::metadata(path) { + let current_stamp = match fs::metadata(path) { Ok(metadata) if metadata.is_file() => FileStamp::new(&metadata), // The file no longer exists -- or a directory has replaced it, which // the walker reports separately. @@ -1843,7 +1843,7 @@ fn scan_file( let entry = cache.files.get(path); let is_modified = entry .and_then(|entry| entry.stamp.as_ref()) - .is_none_or(|cached| !cached.is_unmodified(&stamp)); + .is_none_or(|cached| !cached.is_unmodified(¤t_stamp)); is_toc_changed = is_modified && entry.is_some() && path == cache.toc_path(); if cache.is_current_file(path) { // The connections' sidebars show the TOC from their own IDE's text @@ -1910,7 +1910,7 @@ fn scan_file( // such write leaves the file matching. ScanOutcome::Translated => { if let Some(entry) = cache.files.get_mut(path) { - entry.stamp = Some(stamp); + entry.stamp = Some(current_stamp); } } // A file which can't be translated defines nothing. Committing it @@ -1918,7 +1918,7 @@ fn scan_file( // translatable, and records its stamp, so that later walks skip it // until it changes rather than reading it again. ScanOutcome::Untranslatable => { - cache.commit_file(path, Some(stamp), FileFacts::default()); + cache.commit_file(path, Some(current_stamp), FileFacts::default()); } // The translation may have failed after committing the file's // facts, along with a stamp which matches the file; discard that From 5be38ac1db27b8892d85a0ae134e675aa8dcc1d7 Mon Sep 17 00:00:00 2001 From: "Bryan A. Jones" Date: Sat, 31 Oct 2026 18:01:00 -0500 Subject: [PATCH 3/7] Fix: update to newest dist release. --- .github/workflows/release.yml | 6 +++--- builder/src/main.rs | 2 +- dist-workspace.toml | 10 +++------- 3 files changed, 7 insertions(+), 11 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index aa66a5d5..7f013f1e 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -64,7 +64,7 @@ jobs: # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash - run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/v0.32.0/cargo-dist-installer.sh | sh" + run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/v0.33.1/cargo-dist-installer.sh | sh" - name: Cache dist uses: actions/upload-artifact@v7 with: @@ -124,7 +124,7 @@ jobs: # but keeping it here makes it easier to keep the Node version in sync with the node install for `build-global-artifacts` below. - uses: actions/setup-node@v6 with: - node-version: 24 + node-version: 26 - name: Install Rust non-interactively if not already installed if: ${{ matrix.container }} run: | @@ -252,7 +252,7 @@ jobs: submodules: recursive - uses: actions/setup-node@v6 with: - node-version: 24 + node-version: 26 - name: Install cached dist uses: actions/download-artifact@v8 with: diff --git a/builder/src/main.rs b/builder/src/main.rs index 75523635..119ed0ba 100644 --- a/builder/src/main.rs +++ b/builder/src/main.rs @@ -148,7 +148,7 @@ static WORKSPACE_MANIFEST_PATH: &str = "../Cargo.toml"; // second, explicit pass over it. static BUILDER_PATH: &str = "../builder"; static NAPI_TARGET: &str = "NAPI_TARGET"; -static DIST_VERSION: &str = "0.32.0"; +static DIST_VERSION: &str = "0.33.1"; // Code // ---- diff --git a/dist-workspace.toml b/dist-workspace.toml index b49064ec..7667dabc 100644 --- a/dist-workspace.toml +++ b/dist-workspace.toml @@ -25,14 +25,10 @@ members = ["cargo:."] # Config for 'dist' [dist] -# Extra static files to include in each App. Paths are relative to this file. -include = [ - "client/static", - "server/hashLocations.json", - "server/log4rs.yml", -] +# Extra static files to include in each App (path relative to this Cargo.toml's dir) +include = ["client/static", "server/hashLocations.json", "server/log4rs.yml"] # The preferred dist version to use in CI (Cargo.toml SemVer syntax) -cargo-dist-version = "0.32.0" +cargo-dist-version = "0.33.1" # CI backends to support ci = "github" # The installers to generate for each app From a80d77d88e2fa2c6ec7b262d97b5786d15649a9a Mon Sep 17 00:00:00 2001 From: "Bryan A. Jones" Date: Sat, 31 Oct 2026 21:36:09 -0500 Subject: [PATCH 4/7] Fix: Don't install dist for a release. Remove install --dev option. --- builder/src/main.rs | 83 +++++++++++++++++++++------------------------ 1 file changed, 38 insertions(+), 45 deletions(-) diff --git a/builder/src/main.rs b/builder/src/main.rs index 119ed0ba..d579fe8c 100644 --- a/builder/src/main.rs +++ b/builder/src/main.rs @@ -69,11 +69,7 @@ struct Cli { #[derive(Subcommand)] enum Commands { /// Install all dependencies. - Install { - /// True to install developer-only dependencies. - #[arg(short, long, default_value_t = false)] - dev: bool, - }, + Install, /// Update all dependencies. Update, /// Run formatters and linters. @@ -382,10 +378,8 @@ fn patch_client_libs() -> io::Result<()> { Ok(()) } -fn run_install(dev: bool) -> io::Result<()> { - if dev { - run_script("npm", &["install", "-g", "pnpm"], ".", true)?; - } +fn run_install(cargo_dist: bool) -> io::Result<()> { + run_script("npm", &["install", "-g", "pnpm"], ".", true)?; // See [the client manifest](../../client/package.json5) for an explanation // of `--no-frozen-lockfile`. run_script("pnpm", &["install"], CLIENT_PATH, true)?; @@ -397,22 +391,22 @@ fn run_install(dev: bool) -> io::Result<()> { info "Builder: cargo fetch"; cargo fetch --manifest-path=$BUILDER_PATH/Cargo.toml; )?; - if dev { - // Install the cargo binstall binary, taken from the - // [docs](https://docs.rs/crate/cargo-binstall/1.15.5). - #[cfg(windows)] - run_cmd! { - pwsh -Command "Set-ExecutionPolicy Unrestricted -Scope Process; iex (iwr 'https://raw.githubusercontent.com/cargo-bins/cargo-binstall/main/install-from-binstall-release.ps1').Content"; - }?; - #[cfg(not(windows))] - // The original command had `'=https'`, but single quotes confused - // `cmd_lib` and aren't needed to quote this. Note that `//` in the URL - // is a comment in Rust, so it must be - // [enclosed in quotes](https://github.com/rust-shell-script/rust_cmd_lib/issues/88). - run_cmd! { - curl -L --proto =https --tlsv1.2 -sSf "https://raw.githubusercontent.com/cargo-bins/cargo-binstall/main/install-from-binstall-release.sh" | bash; - }?; - + // Install the cargo binstall binary, taken from the + // [docs](https://docs.rs/crate/cargo-binstall/1.15.5). + #[cfg(windows)] + run_cmd! { + pwsh -Command "Set-ExecutionPolicy Unrestricted -Scope Process; iex (iwr 'https://raw.githubusercontent.com/cargo-bins/cargo-binstall/main/install-from-binstall-release.ps1').Content"; + }?; + #[cfg(not(windows))] + // The original command had `'=https'`, but single quotes confused + // `cmd_lib` and aren't needed to quote this. Note that `//` in the URL + // is a comment in Rust, so it must be + // [enclosed in quotes](https://github.com/rust-shell-script/rust_cmd_lib/issues/88). + run_cmd! { + curl -L --proto =https --tlsv1.2 -sSf "https://raw.githubusercontent.com/cargo-bins/cargo-binstall/main/install-from-binstall-release.sh" | bash; + }?; + + if cargo_dist { // Installing `cargo-dist` using `cargo binstall` fails intermittently // on MacOS. Try another approach. #[cfg(target_os = "macos")] @@ -425,25 +419,24 @@ fn run_install(dev: bool) -> io::Result<()> { info "cargo binstall cargo-dist"; cargo binstall cargo-dist@${DIST_VERSION} --no-confirm; )?; - - run_cmd!( - info "cargo binstall cargo-outdated"; - cargo binstall cargo-outdated --no-confirm; - info "cargo binstall cargo-sort"; - cargo binstall cargo-sort --no-confirm; - info "cargo binstall cargo-audit"; - cargo binstall cargo-audit --no-confirm; - info "cargo binstall cargo-machete"; - cargo binstall cargo-machete --no-confirm; - info "cargo binstall cargo-llvm-cov"; - cargo binstall cargo-llvm-cov --no-confirm; - // Install the required llvm-tools component used by cargo-llvm-cov - // without prompting. - info "rustup component add llvm-tools-preview"; - rustup component add llvm-tools-preview; - )?; } - Ok(()) + + run_cmd!( + info "cargo binstall cargo-outdated"; + cargo binstall cargo-outdated --no-confirm; + info "cargo binstall cargo-sort"; + cargo binstall cargo-sort --no-confirm; + info "cargo binstall cargo-audit"; + cargo binstall cargo-audit --no-confirm; + info "cargo binstall cargo-machete"; + cargo binstall cargo-machete --no-confirm; + info "cargo binstall cargo-llvm-cov"; + cargo binstall cargo-llvm-cov --no-confirm; + // Install the required llvm-tools component used by cargo-llvm-cov + // without prompting. + info "rustup component add llvm-tools-preview"; + rustup component add llvm-tools-preview; + ) } fn run_update() -> io::Result<()> { @@ -802,7 +795,7 @@ fn run_change_version(new_version: &String) -> io::Result<()> { fn run_prerelease() -> io::Result<()> { // Clean out all bundled files before the rebuild. remove_dir_all_if_exists(format!("{CLIENT_PATH}/static/bundled"))?; - run_install(true)?; + run_install(false)?; run_client_build(true, false) } @@ -875,7 +868,7 @@ fn run_coverage() -> io::Result<()> { impl Cli { fn run(self) -> io::Result<()> { match &self.command { - Commands::Install { dev } => run_install(*dev), + Commands::Install => run_install(true), Commands::Update => run_update(), Commands::Flint { check } => run_format_and_lint(*check), Commands::Full => run_full(), From 2921b9aeb89db21681d81192f30545c2043501c7 Mon Sep 17 00:00:00 2001 From: "Bryan A. Jones" Date: Sat, 31 Oct 2026 21:40:15 -0500 Subject: [PATCH 5/7] Fix: update CI. --- .github/workflows/check.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/check.yml b/.github/workflows/check.yml index 8251cc8d..4921440c 100644 --- a/.github/workflows/check.yml +++ b/.github/workflows/check.yml @@ -57,5 +57,5 @@ jobs: - name: Run tests run: | rustup update - ./bt install --dev + ./bt install ./bt full From 3420e959f6f9bc283e3ded9fb09115ea7371ff98 Mon Sep 17 00:00:00 2001 From: "Bryan A. Jones" Date: Sat, 31 Oct 2026 21:54:31 -0500 Subject: [PATCH 6/7] Fix: stop CI on Windows when ./bt install fails. Co-Authored-By: Claude Opus 5.5 --- .github/workflows/check.yml | 7 ++++--- bt.ps1 | 3 +++ 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/.github/workflows/check.yml b/.github/workflows/check.yml index 4921440c..8ca65126 100644 --- a/.github/workflows/check.yml +++ b/.github/workflows/check.yml @@ -52,10 +52,11 @@ jobs: ## server ## extensions/VSCode # On Windows, GitHub Actions runs these commands in PowerShell, which runs - # `bt.ps1`; elsewhere, bash runs `bt`. + # `bt.ps1`; elsewhere, bash runs `bt`. PowerShell, unlike bash, doesn't + # stop when a native command fails, so chain the steps with `&&`. # - name: Run tests run: | rustup update - ./bt install - ./bt full + # + ./bt install && ./bt full diff --git a/bt.ps1 b/bt.ps1 index d1da188d..4e716cda 100644 --- a/bt.ps1 +++ b/bt.ps1 @@ -26,5 +26,8 @@ $manifest_path = Join-Path -Path $PSScriptRoot -ChildPath builder/Cargo.toml echo $manifest_path cargo run --manifest-path=$manifest_path -- $args +# A script's success, as seen by its caller's `&&`, doesn't reflect the exit +# code of its last native command; pass it on explicitly. +exit $LASTEXITCODE # CodeChat Editor lexer: python From 37351f56b6427ad5abf851a585d811b574a6d9c6 Mon Sep 17 00:00:00 2001 From: "Bryan A. Jones" Date: Sat, 31 Oct 2026 21:56:40 -0500 Subject: [PATCH 7/7] Fix: remove old --dev parameter. --- .devcontainer/postCreateCommand.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.devcontainer/postCreateCommand.sh b/.devcontainer/postCreateCommand.sh index 6d56b96a..b82d0eb3 100755 --- a/.devcontainer/postCreateCommand.sh +++ b/.devcontainer/postCreateCommand.sh @@ -29,5 +29,5 @@ if [ -x /usr/local/bin/chrome ] && [ ! -e /usr/local/bin/google-chrome ]; then fi # -./bt install --dev +./bt install ./bt build \ No newline at end of file