setup-pre-commit

Configure Husky pre-commit hooks with lint-staged and Prettier.

2|Updated Apr 11, 2026
One-click install
npx skills add https://github.com/jupes/agent-forge-harness --skill setup-pre-commit-jupes
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: setup-pre-commit
Source: https://github.com/jupes/agent-forge-harness/tree/main/.claude/skills/setup-pre-commit
Command: npx skills add https://github.com/jupes/agent-forge-harness --skill setup-pre-commit-jupes

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires husky, lint-staged, prettier, and includes scripts (resource) and assets (resource) components.

What problem does it solve?

This Skill streamlines the setup of Husky pre-commit hooks, lint-staged configuration, and Prettier formatting in repositories, providing a user-friendly experience to automate code quality checks and formatting standards.

Core Features & Use Cases

  • Pre-commit Hook Setup: Automatically sets up Husky for pre-commit hooks to ensure code quality before committing changes.
  • Formatting and Linting: Configures Prettier and lint-staged for code formatting and linting on staged files.
  • User Approval: Prompts for user approval before making changes to repository configuration.

Quick Start

Run the setup-pre-commit skill in your repository to automatically configure pre-commit hooks and formatting standards.

Frequently Asked Questions about setup-pre-commit

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I set up pre-commit hooks with Husky and lint-staged?

To set up pre-commit hooks with Husky and lint-staged, run the setup-pre-commit skill in your Git repository to automatically configure code quality checks and formatting standards for staged files.

Can I use Prettier to format staged files automatically before committing?

Yes, you can format staged files automatically with Prettier by configuring lint-staged through this setup, which enforces code style standards on Git commit operations.

Does this pre-commit setup require user approval before modifying my repository?

Yes, the pre-commit setup explicitly prompts for user approval before making any changes to your repository configuration, ensuring you maintain control over automated file modifications.

What's the best way to automate code formatting and quality checks in a Git repository?

The best way to automate code formatting and quality checks in a Git repository is configuring Husky pre-commit hooks with lint-staged and Prettier to enforce standards automatically before changes are committed.

Do I need to manually install Husky and lint-staged before running this setup?

You do not need to manually install Husky and lint-staged, as the setup automatically configures these dependencies along with Prettier to establish your pre-commit hooks and formatting rules.