setup-pre-commit

Pass

Audited by Gen Agent Trust Hub on Nov 25, 2026

Risk Level: SAFEEXTERNAL_DOWNLOADSCOMMAND_EXECUTIONPERSISTENCEINDIRECT_PROMPT_INJECTION
Full Analysis
  • [EXTERNAL_DOWNLOADS]: Fetches development dependencies husky, lint-staged, and prettier from the official NPM registry using the project's detected package manager (npm, pnpm, yarn, or bun).
  • [COMMAND_EXECUTION]: Executes shell commands to install dependencies and initialize the hook environment using npx husky init. It also runs npx lint-staged as a verification step.
  • [PERSISTENCE]: Creates a Git pre-commit hook in .husky/pre-commit. This script is configured to automatically run lint-staged, npm run typecheck, and npm run test whenever a user attempts to commit changes to the repository. This capability allows the skill to establish recurring execution of local scripts outside of the active agent session.
  • [INDIRECT_PROMPT_INJECTION]: The skill has a potential ingestion surface for untrusted data as it reads and adapts to local repository files.
  • Ingestion points: Reads package.json, package-lock.json, pnpm-lock.yaml, yarn.lock, and bun.lockb (SKILL.md).
  • Boundary markers: Not specified in the instructions.
  • Capability inventory: Performs file writes, package installations, and command execution via npx (SKILL.md).
  • Sanitization: Not present; the skill directly incorporates values from the local environment into commands and configuration files.
Audit Metadata
Risk Level
SAFE
Analyzed
Nov 25, 2026, 10:11 PM