feat(rebuild): update every installed component from one rebuild

This commit is contained in:
Lap Tran committed 2026-11-23 12:49:53 -05:00
1 parent cff3c8873e
commit 4e1b65b5d2
6 files changed
+280 -20

No files matched your search

+7 -3
View File
@@ -319,7 +319,8 @@ in
# Firstmate companion CLIs (*-axi). None is a Homebrew or Nix formula, so
# install them through Homebrew's npm. tasks-axi is version-gated by firstmate
# (>= 0.2.6 is required before a spawn/teardown automatic backlog transition
# will run), so pin it and reinstall on drift; the rest install when absent.
# will run), so fill a missing or older copy; rebuild.sh moves it on to the
# latest release. The rest install when absent on a fresh machine.
home.activation.axiTools = lib.hm.dag.entryAfter [ "writeBoundary" ] ''
set -euo pipefail
# Activation PATH lacks /opt/homebrew/bin, so npm's `#!/usr/bin/env node`
@@ -331,10 +332,13 @@ in
echo "axiTools: /opt/homebrew/bin/npm missing (declare node in homebrew.brews)" >&2
exit 1
fi
# Pin tasks-axi; reinstall only when the installed version differs.
# tasks-axi: install the firstmate floor only when the copy is missing or
# older. A newer copy is left alone so rebuild.sh's latest-release update
# survives the next switch.
want_tasks_axi="0.2.6"
have_tasks_axi="$(tasks-axi --version 2>/dev/null | head -1 | tr -d '[:space:]')"
if [ "$have_tasks_axi" != "$want_tasks_axi" ]; then
if [ -z "$have_tasks_axi" ] \
|| [ "$(printf '%s\n%s\n' "$want_tasks_axi" "$have_tasks_axi" | sort -V | head -1)" != "$want_tasks_axi" ]; then
"$npm" install -g "tasks-axi@$want_tasks_axi"
fi
# Companion CLIs without a firstmate-enforced version floor: install once.