precommit

Automate Pinot pre-commit checks on modules touched by the current diff.

6.1k|1.5k|Updated May 19, 2014
One-click install
npx skills add https://github.com/apache/pinot --skill precommit-apache
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: precommit
Source: https://github.com/apache/pinot/tree/main/.claude/skills/precommit
Command: npx skills add https://github.com/apache/pinot --skill precommit-apache

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Automates the orchestration of Pinot's pre-commit checks on only the modules touched by the current diff.

Core Features & Use Cases

  • Auto-detects changed modules and runs the following checks: spotless:apply, license:format, checkstyle:check, license:check, and a targeted test-compile for added-line warnings.
  • Applies auto-fixes where possible (spotless and license:format) and surfaces violations for manual review.
  • Suitable for CI pipelines and local development to enforce consistent quality gates across a multi-module Pinot repository.

Quick Start

Run the precommit skill to automatically execute Pinot's pre-commit checks on the modules touched by your current diff and apply auto-fixes where possible.

Frequently Asked Questions about precommit

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

FAQPage Schema
How do I run pre-commit checks on only the modules changed in my git diff?

To run pre-commit checks on changed modules, this skill auto-detects your git diff and applies targeted Maven goals like checkstyle:check and spotless:apply. It orchestrates quality gates exclusively on touched modules, saving build time.

What is the best way to automate license formatting and checkstyle validation for a multi-module Maven project?

Automating license formatting and checkstyle validation is done by executing a sequence of license:format, checkstyle:check, and spotless:apply. This skill orchestrates that exact sequence across multi-module repositories, applying auto-fixes and surfacing violations for review.

Does precommit work with Maven and spotless to apply auto-fixes before opening a pull request?

Yes, precommit works with Maven and spotless to apply auto-fixes before opening a pull request. It runs spotless:apply and license:format automatically, then enforces checkstyle:check and license:check to ensure consistent quality gates.

How do I enforce code quality gates for specific git diff modules in a CI pipeline?

You can enforce code quality gates for specific git diff modules in a CI pipeline by running this skill. It detects changed modules, executes a targeted test-compile for added-line warnings, and reports checkstyle and license violations for review.

What Maven checks are automatically executed when I run precommit on my current diff?

When you run precommit on your current diff, it automatically executes spotless:apply, license:format, checkstyle:check, license:check, and a targeted test-compile. This sequence enforces formatting and validates licenses on changed modules.