KeiSeiKit-1.0/hooks/stop-verify.sh
Parfii-bot 0be354a920 KeiSeiKit-public — clean state
Single-commit clean baseline after security scrub of niche-tells,
project codenames, internal jargon, and contributor-email leaks.

Contents:
- 100 Rust crates (_primitives/_rust/)
- 37 agent manifests (_manifests/) + generated specs (_generated/)
- 67 user-invocable skills (skills/)
- 33 hooks (hooks/)
- Composition blocks (_blocks/)
- Documentation (docs/, README.md)
- TS adapter packages (_ts_packages/)
- Assembler (_assembler/)
- Roles (_roles/)
- Templates (_templates/)
- Forgejo CI (.forgejo/)

Author: Denis Parfionovich <info@greendragon.info>

License: see LICENSE.
2026-05-01 12:09:03 +08:00

33 lines
1,007 B
Bash
Executable file

#!/bin/bash
# Stop Verify — Stop hook
# Checks for uncommitted changes and running compute before session ends
WARNINGS=""
# Check for uncommitted git changes in common project dirs
for dir in ~/Projects/*/; do
if [ -d "${dir}.git" ]; then
CHANGES=$(cd "$dir" && git status --porcelain 2>/dev/null | head -5)
if [ -n "$CHANGES" ]; then
DIRNAME=$(basename "$dir")
COUNT=$(cd "$dir" && git status --porcelain 2>/dev/null | wc -l | tr -d ' ')
WARNINGS="${WARNINGS}UNCOMMITTED: ${DIRNAME} has ${COUNT} uncommitted change(s)\n"
fi
fi
done
# Check for running Modal apps
if command -v modal &> /dev/null; then
MODAL_APPS=$(modal app list 2>/dev/null | grep -i "running" | head -3)
if [ -n "$MODAL_APPS" ]; then
WARNINGS="${WARNINGS}RUNNING MODAL APPS:\n${MODAL_APPS}\n"
fi
fi
if [ -n "$WARNINGS" ]; then
echo -e "=== Session End Verification ===" >&2
echo -e "$WARNINGS" >&2
echo -e "Consider committing or stopping resources before ending." >&2
fi
exit 0