Spaces:
Sleeping
Sleeping
File size: 1,813 Bytes
cc38116 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 | #!/bin/bash
# GSD Workflow Validation Script
# Validates all workflow files for required structure
error_count=0
warning_count=0
workflows_checked=0
echo "βββββββββββββββββββββββββββββββββββββββββββββββββββββ"
echo " GSD βΊ VALIDATING WORKFLOWS"
echo "βββββββββββββββββββββββββββββββββββββββββββββββββββββ"
echo ""
for file in .agent/workflows/*.md; do
((workflows_checked++))
filename=$(basename "$file")
has_errors=false
# Check for frontmatter
if ! head -1 "$file" | grep -q "^---"; then
echo "β $filename: Missing frontmatter"
((error_count++))
has_errors=true
fi
# Check for description
if ! grep -q "description:" "$file"; then
echo "β $filename: Missing description in frontmatter"
((error_count++))
has_errors=true
fi
# Check for process tags (optional but recommended)
if ! grep -q "<process>" "$file"; then
echo "β οΈ $filename: Missing <process> tag"
((warning_count++))
fi
if [ "$has_errors" = false ]; then
echo "β
$filename"
fi
done
echo ""
echo "βββββββββββββββββββββββββββββββββββββββββββββββββββββββ"
echo ""
echo "Workflows checked: $workflows_checked"
echo "Errors: $error_count"
echo "Warnings: $warning_count"
echo ""
if [ $error_count -eq 0 ]; then
echo "β
All workflows valid!"
exit 0
else
echo "β Validation failed"
exit 1
fi
|