项目文件夹

文件
wehub-resource-sync d48cda4081
CI / Test (ubuntu-latest, Node 18.x, bun) (push) Failing after 15m1s
CI / Test (ubuntu-latest, Node 18.x, npm) (push) Failing after 15m1s
CI / Test (ubuntu-latest, Node 18.x, pnpm) (push) Failing after 15m1s
CI / Test (ubuntu-latest, Node 18.x, yarn) (push) Failing after 15m1s
CI / Test (ubuntu-latest, Node 20.x, bun) (push) Failing after 17m13s
CI / Test (ubuntu-latest, Node 20.x, npm) (push) Failing after 18m42s
CI / Test (ubuntu-latest, Node 20.x, pnpm) (push) Failing after 15m0s
CI / Test (ubuntu-latest, Node 20.x, yarn) (push) Failing after 49m44s
CI / Test (ubuntu-latest, Node 22.x, bun) (push) Failing after 51m55s
CI / Test (ubuntu-latest, Node 22.x, pnpm) (push) Failing after 21m57s
CI / Test (ubuntu-latest, Node 22.x, npm) (push) Failing after 37m39s
CI / Test (ubuntu-latest, Node 22.x, yarn) (push) Failing after 34m7s
CI / Validate Components (push) Failing after 37m15s
CI / Python Tests (push) Failing after 10m1s
CI / Security Scan (push) Failing after 10m1s
CI / Lint (push) Failing after 17m12s
CI / Coverage (push) Failing after 20m19s
CI / Test (macos-latest, Node 18.x, bun) (push) Has been cancelled
CI / Test (macos-latest, Node 18.x, npm) (push) Has been cancelled
CI / Test (macos-latest, Node 18.x, pnpm) (push) Has been cancelled
CI / Test (macos-latest, Node 18.x, yarn) (push) Has been cancelled
CI / Test (windows-latest, Node 18.x, npm) (push) Has been cancelled
CI / Test (windows-latest, Node 18.x, pnpm) (push) Has been cancelled
CI / Test (windows-latest, Node 18.x, yarn) (push) Has been cancelled
CI / Test (macos-latest, Node 20.x, bun) (push) Has been cancelled
CI / Test (macos-latest, Node 20.x, npm) (push) Has been cancelled
CI / Test (macos-latest, Node 20.x, pnpm) (push) Has been cancelled
CI / Test (macos-latest, Node 20.x, yarn) (push) Has been cancelled
CI / Test (windows-latest, Node 20.x, npm) (push) Has been cancelled
CI / Test (windows-latest, Node 20.x, pnpm) (push) Has been cancelled
CI / Test (windows-latest, Node 20.x, yarn) (push) Has been cancelled
CI / Test (macos-latest, Node 22.x, bun) (push) Has been cancelled
CI / Test (macos-latest, Node 22.x, npm) (push) Has been cancelled
CI / Test (macos-latest, Node 22.x, pnpm) (push) Has been cancelled
CI / Test (macos-latest, Node 22.x, yarn) (push) Has been cancelled
CI / Test (windows-latest, Node 22.x, npm) (push) Has been cancelled
CI / Test (windows-latest, Node 22.x, pnpm) (push) Has been cancelled
CI / Test (windows-latest, Node 22.x, yarn) (push) Has been cancelled
chore: import upstream snapshot with attribution
2026-07-13 11:55:55 +08:00

113 行
3.6 KiB
Markdown

此文件含有模棱两可的 Unicode 字符
此文件含有可能会与其他字符混淆的 Unicode 字符。 如果您是想特意这样的,可以安全地忽略该警告。 使用 Escape 按钮显示他们。
---
description: "自然言語でファイルを指定するクイックコミット — 何をコミットするかを平易な言葉で記述"
argument-hint: "[ターゲットの説明](空欄 = すべての変更)"
---
# スマートコミット
> PRPs-agentic-engのWirasmによる適応。PRPワークフローシリーズの一部。
**入力**: $ARGUMENTS
---
## フェーズ 1 — ASSESS
```bash
git status --short
```
出力が空の場合 → 停止: "コミットするものがありません。"
変更内容のサマリーをユーザーに表示(追加、変更、削除、未追跡)。
---
## フェーズ 2 — INTERPRET & STAGE
`$ARGUMENTS`を解釈してステージング対象を決定:
| 入力 | 解釈 | Gitコマンド |
|---|---|---|
| *(空 / 未入力)* | すべてをステージ | `git add -A` |
| `staged` | 既にステージ済みのものを使用 | *git addなし)* |
| `*.ts``*.py`など | マッチするglobをステージ | `git add '*.ts'` |
| `except tests` | すべてステージ後、テストをアンステージ | `git add -A && git reset -- '**/*.test.*' '**/*.spec.*' '**/test_*' 2>/dev/null \|\| true` |
| `only new files` | 未追跡ファイルのみステージ | `git ls-files --others --exclude-standard \| grep . && git ls-files --others --exclude-standard \| xargs git add` |
| `the auth changes` | status/diffから解釈 — auth関連ファイルを検出 | `git add <matched files>` |
| 特定のファイル名 | それらのファイルをステージ | `git add <files>` |
自然言語入力("the auth changes"など)の場合、`git status`出力と`git diff`を相互参照して関連ファイルを特定。どのファイルをなぜステージングするかをユーザーに表示。
```bash
git add <determined files>
```
ステージング後、検証:
```bash
git diff --cached --stat
```
ステージングされたものがなければ、停止: "説明に一致するファイルがありません。"
---
## フェーズ 3 — COMMIT
命令形で単一行のコミットメッセージを作成:
```
{type}: {description}
```
タイプ:
- `feat` — 新機能または能力
- `fix` — バグ修正
- `refactor` — 動作を変えないコード再構築
- `docs` — ドキュメント変更
- `test` — テストの追加または更新
- `chore` — ビルド、設定、依存関係
- `perf` — パフォーマンス改善
- `ci` — CI/CD変更
ルール:
- 命令形("added feature"ではなく"add feature"
- タイププレフィックスの後は小文字
- 末尾にピリオドなし
- 72文字以内
- HOWではなくWHATが変わったかを記述
```bash
git commit -m "{type}: {description}"
```
---
## フェーズ 4 — OUTPUT
ユーザーへの報告:
```
Committed: {hash_short}
Message: {type}: {description}
Files: {count} file(s) changed
Next steps:
- git push → リモートにプッシュ
- /prp-pr → プルリクエストを作成
- /code-review → プッシュ前にレビュー
```
---
## 例
| 入力 | 動作 |
|---|---|
| `/prp-commit` | すべてステージ、メッセージを自動生成 |
| `/prp-commit staged` | 既にステージ済みのもののみコミット |
| `/prp-commit *.ts` | すべてのTypeScriptファイルをステージしてコミット |
| `/prp-commit except tests` | テストファイル以外すべてをステージ |
| `/prp-commit the database migration` | statusからDBマイグレーションファイルを検出してステージ |
| `/prp-commit only new files` | 未追跡ファイルのみステージ |