#!/bin/sh
# aionai - post-commit hook
# Auto-logs every commit as a 'change' entry so whichever AI tool you talk to next
# already knows the repo moved — you never hand-update a shared note again.
#
# Install into the repo you want tracked:
#   cp hooks/post-commit .git/hooks/post-commit && chmod +x .git/hooks/post-commit
#
# Set AIONAI_SEGMENT to that project's segment. `aionai` must be on PATH
# (pipx install aionai), or replace it with `uvx aionai` / an absolute path.

export AIONAI_SEGMENT="${AIONAI_SEGMENT:-project}"

aionai log-commit >/dev/null 2>&1 &
