From 52c5e29000ade61a6c8a10151aaf4a2983d789cc Mon Sep 17 00:00:00 2001 From: nrslib <38722970+nrslib@users.noreply.github.com> Date: Sat, 28 Feb 2026 09:38:11 +0900 Subject: [PATCH] docs: require takt review before submitting PRs Rewrite CONTRIBUTING.md to require contributors to run takt -t "#" -w review and post the review summary as a PR comment. Add Japanese version at docs/CONTRIBUTING.ja.md. --- CONTRIBUTING.md | 84 ++++++++++++++++++++--------------------- docs/CONTRIBUTING.ja.md | 64 +++++++++++++++++++++++++++++++ 2 files changed, 104 insertions(+), 44 deletions(-) create mode 100644 docs/CONTRIBUTING.ja.md diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 97d645e..ce46b01 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,62 +1,58 @@ # Contributing to TAKT -Thank you for your interest in contributing to TAKT! +🇯🇵 [日本語版](./docs/CONTRIBUTING.ja.md) -## About This Project - -This project is developed using [TAKT](https://github.com/nrslib/takt). Please understand the following before contributing: - -- **Small, focused changes are preferred** - Bug fixes, typo corrections, documentation improvements -- **Large PRs are difficult to review** - Especially AI-generated bulk changes without explanation - -## How to Contribute - -### Reporting Issues - -1. Search existing issues first -2. Include reproduction steps -3. Include your environment (OS, Node version, etc.) - -### Pull Requests - -**Preferred:** -- Bug fixes with tests -- Documentation improvements -- Small, focused changes -- Typo corrections - -**Difficult to review:** -- Large refactoring -- AI-generated bulk changes -- Feature additions without prior discussion - -### Before Submitting a PR - -1. Open an issue first to discuss the change -2. Keep changes small and focused -3. Include tests if applicable -4. Update documentation if needed +Thank you for your interest in contributing to TAKT! This project uses TAKT's review piece to verify PR quality before merging. ## Development Setup ```bash -# Clone the repository git clone https://github.com/your-username/takt.git cd takt - -# Install dependencies npm install - -# Build npm run build - -# Run tests npm test - -# Lint npm run lint ``` +## How to Contribute + +1. **Open an issue** to discuss the change before starting work +2. **Keep changes small and focused** — bug fixes, documentation improvements, typo corrections are welcome +3. **Include tests** for new behavior +4. **Run the review** before submitting (see below) + +Large refactoring or feature additions without prior discussion are difficult to review and may be declined. + +## Before Submitting a PR + +All PRs must pass the TAKT review process. PRs without a review summary or with unresolved REJECT findings will not be merged. + +### 1. Pass CI checks + +```bash +npm run build +npm run lint +npm test +``` + +### 2. Run TAKT review + +```bash +# Create your PR first, then run review against it +takt -t "#" -w review +``` + +### 3. Confirm APPROVE + +Check the review summary in `.takt/runs/*/reports/review-summary.md`. If the result is **REJECT**, fix the reported issues and re-run the review until you get **APPROVE**. + +If a REJECT finding cannot be resolved (e.g., false positive, intentional design decision), leave a comment on the PR explaining why it remains unresolved. + +### 4. Include the review summary in your PR + +Post the contents of `review-summary.md` as a comment on your PR. This is **required** — it lets maintainers verify that the review was run and passed. + ## Code Style - TypeScript strict mode diff --git a/docs/CONTRIBUTING.ja.md b/docs/CONTRIBUTING.ja.md new file mode 100644 index 0000000..c6bb96f --- /dev/null +++ b/docs/CONTRIBUTING.ja.md @@ -0,0 +1,64 @@ +# TAKT への貢献 + +[English](../CONTRIBUTING.md) + +TAKT への貢献に興味を持っていただきありがとうございます。このプロジェクトでは TAKT のレビューピースを使って PR の品質を確認しています。 + +## 開発環境のセットアップ + +```bash +git clone https://github.com/your-username/takt.git +cd takt +npm install +npm run build +npm test +npm run lint +``` + +## 貢献の流れ + +1. **Issue を起票** して変更内容を議論する +2. **小さく焦点を絞った変更** にする — バグ修正、ドキュメント改善、typo 修正を歓迎します +3. 新しい振る舞いには **テストを含める** +4. PR 提出前に **レビューを実行する**(下記参照) + +事前議論なしの大規模リファクタリングや機能追加はレビューが困難なため、お断りする場合があります。 + +## PR 提出前の必須事項 + +すべての PR は TAKT レビュープロセスを通過する必要があります。レビューサマリーが添付されていない PR、または REJECT 指摘が未解消の PR はマージされません。 + +### 1. CI チェックをパスする + +```bash +npm run build +npm run lint +npm test +``` + +### 2. TAKT レビューを実行する + +```bash +# PR を作成してからレビューを実行 +takt -t "#" -w review +``` + +### 3. APPROVE を確認する + +`.takt/runs/*/reports/review-summary.md` のレビューサマリーを確認してください。結果が **REJECT** の場合は、報告された問題を修正し、**APPROVE** になるまでレビューを再実行してください。 + +REJECT 指摘が解消不可能な場合(誤検知、意図的な設計判断など)は、その理由を PR のコメントに記載してください。 + +### 4. レビューサマリーを PR に含める + +`review-summary.md` の内容を PR のコメントとして投稿してください。これは**必須**です。メンテナーがレビューの実行と通過を確認するために使用します。 + +## コードスタイル + +- TypeScript strict mode +- ESLint によるリンティング +- 巧妙なコードより、シンプルで読みやすいコードを優先 + +## ライセンス + +貢献いただいたコードは MIT ライセンスの下でライセンスされることに同意したものとみなされます。