Skip to content

Instantly share code, notes, and snippets.

@bulldra
Last active January 4, 2026 10:44
Show Gist options
  • Select an option

  • Save bulldra/520b8ef5bc6b7a186bfa10ccbb5ee877 to your computer and use it in GitHub Desktop.

Select an option

Save bulldra/520b8ef5bc6b7a186bfa10ccbb5ee877 to your computer and use it in GitHub Desktop.
name lint
description Runs linting and formatting on frontend (ESLint, Biome) and backend (Ruff). Automatically fixes all errors and warnings. Use when user says /lint, asks to fix lint errors, or wants to check code quality. When we edit code then call lint skill.
version 0.0.1

Lint Skill

この Skill はフロントエンド・バックエンド両方の lint / format を自動修正し、適切なコードベースを保ちます。 返答は日本語で行い、副作用の可能性があるコード変更がある場合はユーザーに確認してください。

実行手順

この skill が呼び出されたら、以下のコマンドを順番に実行してください。

Step 1: Backend (Ruff) 自動修正

cd ./backend && uv run ruff check --fix . && uv run ruff format .

Step 2: Frontend (ESLint) 自動修正

cd ./frontend && pnpm eslint . --fix

Step 3: Frontend (Biome) 自動修正

cd ./frontend && pnpm biome check --write . && pnpm biome format --write .

Step 4: 残存エラー確認

全ての自動修正が完了したら、残存エラーを確認してフロントビルド:

cd ./backend && uv run ruff check .
cd ./frontend && pnpm eslint . && pnpm biome check .
cd ./frontend && pnpm tsc -b && pnpm build

Step 5: 残存エラーの修正

  • 残っている error と warning について修正方針をプランニング
  • 修正方針が明瞭でない場合や副作用が大きい場合には質問をして方針を明確化
  • プランニングされた修正方針に従って AI Agent によるソースコード修正を実施
  • アプリケーションの動作に影響しない部分であっても、コード品質向上のために修正を実施
  • 修正が完了したら再度 step1 から実行し、エラーを修正(3 回まで繰り返し)

重要なルール

  1. 自動修正を最優先: 必ず --fix オプション付きで実行する
  2. 全ステップ実行: Step 1-3 を全て実行してから Step 4 で確認
  3. 残存エラーのみ報告: 自動修正できなかった error と warning をユーザーに報告
  4. 残存エラーの自動修正: 自動修正できなかった error と warning についても AI Agent によって可能な限り修正

出力フォーマット

実行完了後、以下の形式で報告:

## Lint Auto-Fix 完了

### Backend (Ruff)
- 修正: XX issues
- 残存: YY errors

### Frontend (ESLint)
- 修正: XX issues
- 残存: YY errors

### Frontend (Biome)
- 修正: XX issues
- 残存: YY errors

### 手動修正が必要
- [ファイル:行番号] エラー内容
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment