diff --git a/automation/validate-setup.sh b/automation/validate-setup.sh index 1d369c7..94dcf15 100755 --- a/automation/validate-setup.sh +++ b/automation/validate-setup.sh @@ -81,7 +81,7 @@ echo "" # Check skills echo "=== Skills ===" -for skill in gmail gcal k8s-quick-status sysadmin-health usage programmer-add-project; do +for skill in gmail gcal gtasks k8s-quick-status sysadmin-health usage programmer-add-project morning-report stock-lookup rag-search; do skill_dir="${CLAUDE_DIR}/skills/${skill}" if [[ -f "${skill_dir}/SKILL.md" ]]; then pass "${skill}/SKILL.md exists" @@ -126,6 +126,54 @@ for file in component-registry.json autonomy-levels.json model-policy.json; do done echo "" +# Check hybrid format enforcement +echo "=== Hybrid Format (md/json/yaml) ===" + +# Agents must be .md +non_md_agents=$(find "${CLAUDE_DIR}/agents" -type f ! -name "*.md" ! -name "README*" 2>/dev/null | wc -l) +if [[ ${non_md_agents} -eq 0 ]]; then + pass "All agent files are .md" +else + fail "Found ${non_md_agents} non-.md files in agents/" + find "${CLAUDE_DIR}/agents" -type f ! -name "*.md" ! -name "README*" 2>/dev/null | while read f; do + echo " - $(basename "$f")" + done +fi + +# Commands must be .md +non_md_commands=$(find "${CLAUDE_DIR}/commands" -type f ! -name "*.md" ! -name "README*" 2>/dev/null | wc -l) +if [[ ${non_md_commands} -eq 0 ]]; then + pass "All command files are .md" +else + fail "Found ${non_md_commands} non-.md files in commands/" + find "${CLAUDE_DIR}/commands" -type f ! -name "*.md" ! -name "README*" 2>/dev/null | while read f; do + echo " - $(basename "$f")" + done +fi + +# Workflows must be .yaml +non_yaml_workflows=$(find "${CLAUDE_DIR}/workflows" -type f ! -name "*.yaml" ! -name "*.yml" ! -name "README*" 2>/dev/null | wc -l) +if [[ ${non_yaml_workflows} -eq 0 ]]; then + pass "All workflow files are .yaml" +else + fail "Found ${non_yaml_workflows} non-.yaml files in workflows/" + find "${CLAUDE_DIR}/workflows" -type f ! -name "*.yaml" ! -name "*.yml" ! -name "README*" 2>/dev/null | while read f; do + echo " - $(basename "$f")" + done +fi + +# State must be .json (excluding subdirectories with their own patterns) +non_json_state=$(find "${CLAUDE_DIR}/state" -maxdepth 1 -type f ! -name "*.json" ! -name "README*" 2>/dev/null | wc -l) +if [[ ${non_json_state} -eq 0 ]]; then + pass "All top-level state files are .json" +else + fail "Found ${non_json_state} non-.json files in state/" + find "${CLAUDE_DIR}/state" -maxdepth 1 -type f ! -name "*.json" ! -name "README*" 2>/dev/null | while read f; do + echo " - $(basename "$f")" + done +fi +echo "" + # Check Gmail setup echo "=== Gmail Integration ===" if [[ -d "${CLAUDE_DIR}/mcp/gmail/venv" ]]; then