Skip to content

CLAUDE.md の整理と Claude Code のフック追加 - #13

Merged
cssho merged 1 commit into
masterfrom
claude-config
Nov 6, 2026
Merged

cssho merged 1 commit into
masterfrom
claude-config

Conversation

@cssho

@cssho cssho commented Nov 6, 2026

Copy link
Copy Markdown
Owner

概要

これまでの作業を見直して CLAUDE.md を整理し、Claude Code のフックを追加しました。

CLAUDE.md

  • 「リポジトリ運用」の節を追加(コミット・PR は依頼時のみ、マージはユーザー、マージ後の後片付け)
  • 「郵便番号データ・住所照合」の節を追加(Shift_JIS の読み込み、照合の性能、事業所名の部分一致の扱い)
  • 改行は core.autocrlf=true に従う(Windows では CRLF)と明記
  • 公開済みバージョンは出し直せないこと、gh actions-lock --json=... の書き方、パッケージ検証が片方向であることを追記

フック(.claude/settings.json、.claude/hooks/post-edit.mjs)

  • Write / Edit 後、.cs に BOM がなければ付ける
  • .github/workflows/*.yml を編集したら gh actions-lock --verify-local を実行し、不一致なら Claude に知らせる
  • 実行には Node.js が必要(gh がない環境では何もしない)

確認

  • BOM なしの .cs に一度だけ BOM が付き、既存ファイルは変わらないこと
  • ワークフローの ref を変えると不一致が検出されること
  • セッション内の Write でフックが実際に動くこと

🤖 Generated with Claude Code

https://claude.ai/code/session_01HNb8H3ydQTR8dWU8d28osE

- CLAUDE.md: リポジトリ運用、郵便番号データ・住所照合の節を追加。改行は core.autocrlf に従うことを明記し、リリース・actions.lock の注意点を追記
- .claude/settings.json: Write / Edit 後に .cs へ BOM を補い、ワークフロー編集時に gh actions-lock --verify-local を実行するフック

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01HNb8H3ydQTR8dWU8d28osE
@cssho
cssho merged commit eb55811 into master Nov 6, 2026
7 checks passed
@cssho
cssho deleted the claude-config branch November 6, 2026 11:20
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.

1 participant