Skip to content
Shell
559 B
Raw Blame
#!/bin/bash
# Auto Documentation: Generates plain-English docs for what was built

FILE_PATH="$1"
PROJECT_DIR=$(pwd)

# Only run for code files
FILE_EXT="${FILE_PATH##*.}"
case "$FILE_EXT" in
  ts|tsx|js|jsx|py)
    # Check if this is a new feature file (not in a previous commit)
    if ! git ls-files --error-unmatch "$FILE_PATH" > /dev/null 2>&1; then
      echo "πŸ“ New feature file detected: $FILE_PATH"
      echo "πŸ’‘ Claude will create plain-English documentation"
      echo "CLAUDE_ACTION: document_feature:$FILE_PATH"
    fi
    ;;
esac

exit 0