mcpField
L
lefthook

lefthook

github.com/fandhe-aiDevelopment41.2k installsUpdated 4d ago
Repository

About lefthook

A documentation-reference skill for Lefthook that organizes its documentation by task. It covers installation, configuration, commands, integrations, examples, and AI-agent hook settings for Lefthook v2.2.2.

Key features

  1. 01Task-to-category documentation map
  2. 02Installation methods and setup guidance
  3. 03Hook, command, and script configuration
  4. 04CLI usage and environment variables
  5. 05Examples for integrations and local overrides

Use cases

  1. 01Choose an installation method for Lefthook
  2. 02Configure Git hooks and commands
  3. 03Review environment-variable controls
  4. 04Set up AI-agent hook configuration

Install

Copy the command and run it in a terminal.

$npx skills add https://github.com/fandhe-ai/agent-reference-skills --skill lefthook

After installing, type/lefthookin Claude Code to confirm it loaded.

Bundled files

References and scripts installed along with SKILL.md.

references/configuration/
ai.md
command-settings.md
global-settings.md
hook-settings.md
README.md
remotes.md
script-settings.md
source-dir.md
references/examples/
commitlint.md
filters.md
lefthook-local.md
protect-branch.md
README.md
remotes.md
skip.md
stage-fixed.md
wrap-commands.md
references/installation/
alpine.md
arch.md
deb.md
devbox.md
go.md
homebrew.md
manual.md
mise.md
node.md
overview.md
php.md
python.md
README.md

Details

From the project README

Lefthook リファレンス

Lefthook(lefthook.dev)の全ドキュメントを網羅したスキル。 ユーザーのタスクに応じて適切な README.md を読み、そこから個別ファイルへ辿ること。

対象 Lefthook v2.2.2(2026-10 時点、GitHub タグ v2.2.2 の docs/ が原本)。

ディレクトリ構成

skills/lefthook/
  SKILL.md
  references/
    installation/
      README.md
      overview.md
      node.md
      ruby.md
      go.md
      python.md
      php.md
      swift.md
      homebrew.md
      winget.md
      scoop.md
      deb.md
      rpm.md
      alpine.md
      arch.md
      snap.md
      devbox.md
      mise.md
      manual.md
    configuration/
      README.md
      ai.md
      global-settings.md
      hook-settings.md
      command-settings.md
      script-settings.md
      source-dir.md
      remotes.md
    usage/
      README.md
      commands.md
      environment-variables.md
    examples/
      README.md
      commitlint.md
      filters.md
      lefthook-local.md
      protect-branch.md
      remotes.md
      skip.md
      stage-fixed.md
      wrap-commands.md
  samples/
    README.md
    basic-setup.md
    parallel-execution.md
    auto-fix-and-stage.md
    commitlint-integration.md
    local-override.md
    conditional-skip.md
    monorepo-setup.md
    shared-config-via-remotes.md
  scripts/
    README.md
    cli.md
    install.md
    run-with-env.md

探索手順

タスクからカテゴリを引き、カテゴリの README.md で目的のページを特定する:

  1. 下記マッピング表でタスクに対応するカテゴリを探す
  2. そのカテゴリの references/{category}/README.md を参照して目的のページを特定する
  3. 該当ページの .md を Read して詳細を確認する

タスク → カテゴリ マッピング

タスクカテゴリ参照 README
Lefthook のインストール・セットアップinstallationreferences/installation/README.md
npm / yarn / pnpm / pip / gem / composer でのインストールinstallationreferences/installation/README.md
Homebrew / Scoop / Winget / APK / AUR でのインストールinstallationreferences/installation/README.md
バイナリ手動インストール・mise / devbox 対応installationreferences/installation/README.md
lefthook.yml のグローバル設定configurationreferences/configuration/README.md
Hook 設定(parallel, piped, follow, skip)configurationreferences/configuration/README.md
Command 設定(run, glob, files, stage_fixed)configurationreferences/configuration/README.md
Script 設定・source_dir の変更configurationreferences/configuration/README.md
remotes による設定共有configurationreferences/configuration/README.md
AI エージェント hooks(ai: claude / codex / cursor / copilot の hooks 設定ファイル生成)configurationreferences/configuration/README.md
エディタ補完・JSON schema(lefthook.dev/schema.json)configurationreferences/configuration/README.md
lefthook install / run / add / validate / dumpusagereferences/usage/README.md
環境変数(LEFTHOOK, LEFTHOOK_VERBOSE 等)による制御usagereferences/usage/README.md
commitlint / Commitizen 統合examplesreferences/examples/README.md
ファイルフィルタリング(glob / staged_files / tags)examplesreferences/examples/README.md
lefthook-local.yml でのローカルオーバーライドexamplesreferences/examples/README.md
条件付きスキップ・ブランチ制限examplesreferences/examples/README.md
現在のブランチが main / master のときの push を pre-push でブロック(push 先 ref は判定しない)examplesreferences/examples/README.md
典型的な使い方を知りたいsamplessamples/README.md
インストール・CLI コマンドを知りたいscriptsscripts/README.md

Comments

Markdown supported