The accidental, untested beads v1.2.1 release migrated the schema from v53 to v65 while the supported v1.2.2 binary expects v53, so bd refused to run. All three databases on the shared server were affected, not just this one -- archie_core, ai_sdk and beads_global were each at v65. Recovery per docs/RECOVERY-1.2.1.md (beads v1.2.2): rolled the schema cursor back to v53 in each database and re-tracked the events table to restore audit-event versioning. Issue data was not touched; 508 issues before and after. Data the 1.2.1 release wrote into 1.2.x-only structures (work-lease state, events-journal rows, provenance, storage_class markers) remains in the database and is simply unused by the 1.1 line. shared-server flips to false, so this project now runs its own Dolt server out of .beads/dolt instead of sharing /home/sam/.beads/shared-server with ai_sdk and beads_global. Note bd 1.2.2 has no "embeddeddolt" mode -- that layout belongs to the older embedded builds; project-local server is the equivalent today, and .beads/dolt is already gitignored. Hooks were reinstalled: the installed set was still 1.2.1. The rest of the config diff is bd reflowing the YAML indentation on write.
34 lines
1.3 KiB
Bash
Executable File
34 lines
1.3 KiB
Bash
Executable File
#!/usr/bin/env sh
|
|
# --- BEGIN BEADS INTEGRATION v1.2.2 ---
|
|
# This section is managed by beads. Do not remove these markers.
|
|
if command -v bd >/dev/null 2>&1; then
|
|
export BD_GIT_HOOK=1
|
|
_bd_timeout=${BEADS_HOOK_TIMEOUT:-300}
|
|
_bd_used_perl=0
|
|
if command -v timeout >/dev/null 2>&1; then
|
|
timeout "$_bd_timeout" bd hooks run prepare-commit-msg "$@"
|
|
_bd_exit=$?
|
|
elif command -v gtimeout >/dev/null 2>&1; then
|
|
gtimeout "$_bd_timeout" bd hooks run prepare-commit-msg "$@"
|
|
_bd_exit=$?
|
|
elif command -v perl >/dev/null 2>&1; then
|
|
_bd_used_perl=1
|
|
perl -e 'alarm shift; exec @ARGV' "$_bd_timeout" bd hooks run prepare-commit-msg "$@"
|
|
_bd_exit=$?
|
|
else
|
|
echo >&2 "beads: hook 'prepare-commit-msg' running without timeout; install coreutils or perl to enable BEADS_HOOK_TIMEOUT"
|
|
bd hooks run prepare-commit-msg "$@"
|
|
_bd_exit=$?
|
|
fi
|
|
if [ $_bd_exit -eq 124 ] || { [ $_bd_used_perl -eq 1 ] && [ $_bd_exit -eq 142 ]; }; then
|
|
echo >&2 "beads: hook 'prepare-commit-msg' timed out after ${_bd_timeout}s — continuing without beads"
|
|
_bd_exit=0
|
|
fi
|
|
if [ $_bd_exit -eq 3 ]; then
|
|
echo >&2 "beads: database not initialized — skipping hook 'prepare-commit-msg'"
|
|
_bd_exit=0
|
|
fi
|
|
if [ $_bd_exit -ne 0 ]; then exit $_bd_exit; fi
|
|
fi
|
|
# --- END BEADS INTEGRATION v1.2.2 ---
|