1
0

fix: enhance debug output during script execution in setup.sh

This commit is contained in:
2025-08-04 22:15:33 -05:00
parent 59eb18ca76
commit 0b3b6f441c

View File

@@ -29,22 +29,34 @@ if [ -d "$DOTFILES_DIR/scripts" ]; then
# Get list of numbered scripts, sorted
script_files=$(find "$DOTFILES_DIR/scripts" -name '[0-9][0-9]-*.sh' -type f | sort)
echo "DEBUG: script_files found:"
echo "$script_files"
echo "DEBUG: Starting loop..."
for script in $script_files; do
echo "DEBUG: Processing script: '$script'"
if [ -f "$script" ]; then
script_name=$(basename "$script")
log_info "Running $script_name..."
if bash "$script" "$DOTFILES_DIR"; then
log_success "$script_name completed"
echo "DEBUG: Script '$script_name' completed successfully"
else
log_error "$script_name failed"
exit 1
fi
((script_count++))
echo "DEBUG: script_count is now: $script_count"
else
echo "DEBUG: '$script' is not a file"
fi
echo "DEBUG: End of loop iteration for '$script'"
done
echo "DEBUG: Loop completed. Final script_count: $script_count"
if [ $script_count -eq 0 ]; then
log_warning "No numbered scripts found in scripts/ directory"
else