sync: auto-sync from GURU-BEAST-ROG at 2026-06-15 06:28:46

Author: Mike Swanson
Machine: GURU-BEAST-ROG
Timestamp: 2026-06-15 06:28:46
This commit is contained in:
2026-06-15 06:28:51 -07:00
parent b186856d6f
commit 153be4abec
2 changed files with 11 additions and 7 deletions

View File

@@ -508,20 +508,24 @@ if [ "$INCOMING_COUNT" -gt 0 ]; then
# Submodules may have advanced via the parent's gitlinks. Update them to match, # Submodules may have advanced via the parent's gitlinks. Update them to match,
# but tolerate per-submodule failures (e.g., transient dead refs in history) — # but tolerate per-submodule failures (e.g., transient dead refs in history) —
# the working tree is still useful even if one submodule can't catch up. # the working tree is still useful even if one submodule can't catch up.
# First attempt's output is captured (not streamed): a recurring, auto-healable
# cause is an untracked file colliding with the incoming gitlink commit, and git's
# raw "fatal: Unable to checkout" reads alarmingly right before a clean resolve.
# Only surface the raw output if the resolve+retry below also fails.
set +e set +e
git submodule update --init --recursive --quiet 2>&1 | grep -v '^$' || true SUB_OUT=$(git submodule update --init --recursive --quiet 2>&1)
SUB_RC=${PIPESTATUS[0]} SUB_RC=$?
set -e set -e
if [ "$SUB_RC" -ne 0 ]; then if [ "$SUB_RC" -ne 0 ]; then
# Most common recurring cause: an untracked file in a submodule colliding # Move any untracked files colliding with the incoming commit aside, retry once.
# with the incoming gitlink commit. Resolve non-destructively and retry once.
if resolve_submodule_collisions; then if resolve_submodule_collisions; then
set +e set +e
git submodule update --init --recursive --quiet 2>&1 | grep -v '^$' || true SUB_OUT=$(git submodule update --init --recursive --quiet 2>&1)
SUB_RC=${PIPESTATUS[0]} SUB_RC=$?
set -e set -e
fi fi
if [ "$SUB_RC" -ne 0 ]; then if [ "$SUB_RC" -ne 0 ]; then
[ -n "$SUB_OUT" ] && printf '%s\n' "$SUB_OUT" | grep -v '^$'
echo -e "${YELLOW}[WARNING]${NC} One or more submodules failed to update — likely a transient dead ref. Parent repo is current; investigate the submodule manually if a pointer is wrong." echo -e "${YELLOW}[WARNING]${NC} One or more submodules failed to update — likely a transient dead ref. Parent repo is current; investigate the submodule manually if a pointer is wrong."
else else
echo -e "${GREEN}[OK]${NC} Submodules reconciled (set aside colliding untracked file(s))." echo -e "${GREEN}[OK]${NC} Submodules reconciled (set aside colliding untracked file(s))."

View File

@@ -15,4 +15,4 @@ Format: `YYYY-MM-DD | MACHINE | command/skill | error (brief)`
2026-06-14 | GURU-BEAST-ROG | coord skill (coord.py msg send) | `py "$CLAUDETOOLS_ROOT/.claude/skills/coord/scripts/coord.py"` failed — `$CLAUDETOOLS_ROOT` is not exported in fresh Git-bash shells here, so the path resolved under `C:\Program Files\Git\`. [RESOLVED 2026-06-14] Added `.claude/scripts/ensure-settings-env.py` (seeds `env.CLAUDETOOLS_ROOT` in per-machine `settings.local.json` from `identity.json`); Claude Code injects it into every Bash call. Wired into ONBOARDING.md + broadcast to fleet. Effective next session start. 2026-06-14 | GURU-BEAST-ROG | coord skill (coord.py msg send) | `py "$CLAUDETOOLS_ROOT/.claude/skills/coord/scripts/coord.py"` failed — `$CLAUDETOOLS_ROOT` is not exported in fresh Git-bash shells here, so the path resolved under `C:\Program Files\Git\`. [RESOLVED 2026-06-14] Added `.claude/scripts/ensure-settings-env.py` (seeds `env.CLAUDETOOLS_ROOT` in per-machine `settings.local.json` from `identity.json`); Claude Code injects it into every Bash call. Wired into ONBOARDING.md + broadcast to fleet. Effective next session start.
2026-06-14 | GURU-BEAST-ROG | /sync (sync.sh Phase 3, submodule update) | submodule `projects/msp-tools/guru-rmm` checkout of f38da05 aborted: untracked `docs/RMM_THOUGHTS.md` would be overwritten. Parent repo synced fine; submodule pointer left lagging. Recurring transient — candidate for sync.sh to stash/skip untracked submodule files. 2026-06-14 | GURU-BEAST-ROG | /sync (sync.sh Phase 3, submodule update) | submodule `projects/msp-tools/guru-rmm` checkout of f38da05 aborted: untracked `docs/RMM_THOUGHTS.md` would be overwritten. Parent repo synced fine; submodule pointer left lagging. Recurring transient. [RESOLVED 2026-06-15] sync.sh now has `resolve_submodule_collisions()` — on the abort it moves only the untracked files the incoming commit tracks aside to `<file>.synced-aside-<UTCstamp>` (content preserved, NOT --force) then retries once. Verified live: guru-rmm advanced ed92097->f38da05; the aside copy held 94 lines of un-committed 2026-06-08 thoughts (rescued, not lost — needs manual merge into canonical RMM_THOUGHTS.md).