Skip to content

feat: 個人設定の rules/user-* 推奨ガイダンスと /audit-config コマンド(v0.72.0)#142

Merged
okash1n merged 1 commit into
mainfrom
feat/personal-config-guidance
Jun 12, 2026
Merged

feat: 個人設定の rules/user-* 推奨ガイダンスと /audit-config コマンド(v0.72.0)#142
okash1n merged 1 commit into
mainfrom
feat/personal-config-guidance

Conversation

@okash1n

@okash1n okash1n commented Jun 12, 2026

Copy link
Copy Markdown
Contributor

概要

v0.71.1 で予約した user-* 名前空間の活用面を整備する 3 点セット。

変更内容

  1. README ja/en: 個人の常時ロード指示は CLAUDE.md ユーザーセクションより ~/.claude/rules/user-*.md 推奨と明記。推奨理由は正直に「update との完全分離・ファイル単位管理・予約名保証」とし、コンテキストコストは同一であることも記載
  2. update 時の非ブロック tip: CLAUDE.md ユーザーセクションに実コンテンツ(見出し・HTML コメント・空行以外)がある場合のみ、update の CLAUDE.md 処理直後に info 1 行を表示。プロンプトなし・dismiss 不要のレベルに抑制(定常 nag を排した本キットの方針と整合)。検出ヘルパーは CRLF 耐性つき + 3 ケースのユニットテスト
  3. /audit-config コマンド新設(20 → 21 個): 個人設定を babysitting / over-prescription / stale-premise / context-tax の 4 レンズで監査。削りすぎ防止を明文化(推測不能な個人選好は削除対象外、context-tax は実確認必須、出力は提案のみで適用はユーザー承認後)

検証

  • unit 350/350 / scenarios 44 Pass + 1 Skip / shellcheck green
  • 内部レビュー(code-reviewer agent): low 2 件(awk の CRLF 非対応・README 表への新コマンド未記載)+ trivial 1 件(CHANGELOG 文言)→ すべて修正済み。awk の exit/END 干渉バグはテストが先に検出して修正済み

- README ja/en に個人設定の推奨配置(rules/user-*.md)を明記
- update 時、CLAUDE.md ユーザーセクションに実コンテンツがある場合のみ非ブロックの tip を 1 行表示(CRLF 耐性つき検出ヘルパー + テスト)
- /audit-config 新設: 4 分類レンズ + 削りすぎ防止 + 提案のみ出力の個人設定監査コマンド
Copilot AI review requested due to automatic review settings June 12, 2026 06:44
@okash1n okash1n merged commit 6e18150 into main Jun 12, 2026
12 checks passed
@okash1n okash1n deleted the feat/personal-config-guidance branch June 12, 2026 06:47

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR builds on the reserved user-* namespace by documenting the recommended location for personal always-loaded rules, adding a non-blocking update-time tip when users still keep content in the CLAUDE.md user section, and introducing a new /audit-config command to review personal config for outdated or redundant instructions.

Changes:

  • Add /audit-config slash command to audit user-owned config through four lenses (babysitting / over-prescription / stale-premise / context-tax).
  • Update README (ja/en) to recommend ~/.claude/rules/user-*.md for personal always-loaded preferences and reflect the command count increase (20 → 21).
  • Add _claude_md_user_section_has_content and show a one-line info tip during update when the CLAUDE.md user section contains real content, with unit test coverage.

Reviewed changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
tests/unit/test-update-refactor.sh Adds unit test coverage for detecting real content in the CLAUDE.md user section (drives update tip).
README.md Documents user-*.md recommendation (ja) and adds /audit-config; updates command counts.
README.en.md Documents user-*.md recommendation (en) and adds /audit-config; updates command counts.
lib/update.sh Adds user-section content detection helper and prints a non-blocking tip during update when appropriate.
i18n/ja/strings.sh Adds localized update tip string for user-*.md guidance.
i18n/en/strings.sh Adds localized update tip string for user-*.md guidance.
commands/audit-config.md Introduces the /audit-config command definition and instructions.
CHANGELOG.md Adds release notes for v0.72.0 covering the new guidance, tip, and command.

Comment on lines +98 to +102
{
test_name="update: user-section content detection drives the rules/user-* tip"
_ust_tmp="$(mktemp -d)"
_SETUP_TMP_FILES+=("$_ust_tmp")
# scaffold only (heading + placeholder comment) → no tip
Comment thread commands/audit-config.md
@@ -0,0 +1,55 @@
---
description: Audit your personal Claude Code config for outdated, model-babysitting, or redundant instructions.
argument-hint: [global|project|all]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants