Script fixes

This commit is contained in:
David Tomaschik
2026-08-26 16:56:15 -07:00
parent 3666115090
commit ae111baa2b
8 changed files with 62 additions and 29 deletions

View File

@@ -57,9 +57,9 @@ SUB_HOOK_DIR="${HOOKS_DIR}/${CALLED_AS}.d"
if [ -d "$SUB_HOOK_DIR" ]; then
# Sort files naturally so 01- runs before 02-
for script in $(ls "$SUB_HOOK_DIR" | sort); do
FULL_PATH="$SUB_HOOK_DIR/$script"
for FULL_PATH in "$SUB_HOOK_DIR"/*; do
[ -x "$FULL_PATH" ] || continue
script=$(basename "$FULL_PATH")
# Replay stdin if we captured it, otherwise execute normally
if [ -n "$STDIN_DATA" ]; then