@amsterdamdatalabs/adl-agent-control-darwin-arm64 0.1.4 → 0.1.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/bin/adl +1 -1
  2. package/bin/reconcile +15 -4
  3. package/package.json +1 -1
package/bin/adl CHANGED
@@ -1,4 +1,4 @@
1
1
  [diffend] Oversized file quarantined before diffing.
2
2
  name: package/bin/adl
3
3
  size: 63812082 bytes
4
- sha256: 6e9c3201604d28fed30794ddca8c0a50e23902b16da3a83231cc42371bf2f5a4
4
+ sha256: 11d1d7de31df0e008629dfdd2bb8c2ba3091a00c1ed23b35524bd08524ac4b45
package/bin/reconcile CHANGED
@@ -407,12 +407,14 @@ run_brew_upgrade_all() {
407
407
  echo "brew upgrade: nothing outdated"
408
408
  return 0
409
409
  fi
410
- local upgrade_output upgrade_status=0
410
+ local upgrade_status=0
411
411
  # Routed through run_brew itself (same owner/cwd/stdin wiring as every
412
412
  # other brew mutation in this file), bounded by run_with_timeout so a
413
413
  # network-stalled `brew upgrade` cannot hang the rest of this run forever.
414
- upgrade_output="$(run_with_timeout "$BREW_UPGRADE_ALL_TIMEOUT_SECONDS" run_brew upgrade 2>&1)" || upgrade_status=$?
415
- printf '%s\n' "$upgrade_output"
414
+ # brew's output streams live -- never captured and printed at the end,
415
+ # which left a long upgrade silent for minutes and looking stuck.
416
+ echo "brew upgrade: $formulae_count formulae, $casks_count casks outdated; upgrading (timeout ${BREW_UPGRADE_ALL_TIMEOUT_SECONDS}s)"
417
+ run_with_timeout "$BREW_UPGRADE_ALL_TIMEOUT_SECONDS" run_brew upgrade 2>&1 || upgrade_status=$?
416
418
  if [[ "$upgrade_status" -eq 124 ]]; then
417
419
  echo "brew upgrade timed out after ${BREW_UPGRADE_ALL_TIMEOUT_SECONDS}s" >&2
418
420
  return 1
@@ -2519,7 +2521,16 @@ fi
2519
2521
  # in unnoticed.
2520
2522
  if [[ "$mode" != apply ]]; then
2521
2523
  echo "global-tools: lean-ctx observe/raw-hook strip mode=plan home=$administrator_home"
2522
- "$script_dir/lean-ctx-observe-strip" --home "$administrator_home" --mode plan
2524
+ # Plan runs either unprivileged (the administrator's own shell) or under
2525
+ # sudo (fleet-cutover.sh's plan). As root it must drop to the administrator
2526
+ # exactly like apply: lean-ctx-observe-strip refuses root against a
2527
+ # non-root home (m5 cutover plan, 2026-09-29).
2528
+ if [[ "$EUID" -eq 0 && "$administrator" != root ]]; then
2529
+ (cd /tmp && sudo -u "$administrator" -H env PATH="${brew_bin%/*}:/usr/bin:/bin" \
2530
+ "$script_dir/lean-ctx-observe-strip" --home "$administrator_home" --mode plan)
2531
+ else
2532
+ "$script_dir/lean-ctx-observe-strip" --home "$administrator_home" --mode plan
2533
+ fi
2523
2534
  else
2524
2535
  echo "global-tools: lean-ctx observe/raw-hook strip mode=apply home=$administrator_home (as $administrator)"
2525
2536
  # stdout captured (then re-printed) so its own "backed up previous config
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@amsterdamdatalabs/adl-agent-control-darwin-arm64",
3
- "version": "0.1.4",
3
+ "version": "0.1.6",
4
4
  "description": "adl CLI binary for darwin/arm64 (agent identity + Azure DevOps front door — see docs/architecture/cli-design.md)",
5
5
  "license": "UNLICENSED",
6
6
  "os": [