When starting or scaffolding any project, set up formatting, linting, import sorting, type checking, and pre-commit hooks before writing application code. This prevents the painful scenario of adding these tools later and facing thousands of lines of formatting changes in a single commit.
Determine the project type from existing files or the scaffolding context:
| pyproject.toml, setup.py, requirements.txt, .py files | Python | | package.json, tsconfig.json, .ts/.js/.tsx files | JavaScript/TypeScript | | Both present | Monorepo — configure each ecosystem separately |
スキャフォールディングまたは新しいプロジェクトの開始時に、書式設定、リンティング、インポートの並べ替え、型チェック、および事前コミットフックを設定します。このスキルは、新しいプロジェクトの作成時、リポジトリの初期化時、アプリのスキャフォールディング時、またはユーザーが既存のプロジェクトに lint/formatting の追加を要求したときに使用します。トリガー: 「新しいプロジェクト」、「足場」、「初期化」、「リンティングのセットアップ」、「フォーマッタの追加」、「コミット前フックの追加」、「バイオームの構成」、「ラフの構成」。目標は、初日からコード品質ツールを確立して、後で面倒な一括修正を行うのではなく、問題を段階的に検出できるようにすることです。 ソース: rarestg/rarestg-skills。