Serena の設定: 利用者ごとに書き換わる設定が追跡されていて、認証の秘密が誤ってコミットへ入りうる → 無視して追跡から外す - #836
Merged
Merged
Conversation
`.serena/serena_config.yml` は利用者ごとに書き換わる設定で、認証の秘密 (`auth_secret`)を持つ。追跡したままだと、手元の変更が `git add -u` や `commit -a` でコミットへ入りうる。 - 無視の設定へ 1 行足し、追跡から外す(`git rm --cached`) - 手元のファイルは消えない。既存の利用者は取り込んだ後も同じ内容を使い続ける - 履歴に秘密は入っていない(コミット済みの版に `auth_secret` の行は無い) Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
.serena/serena_config.ymlは Serena MCP が利用者ごとに書き換える設定で、認証の秘密(auth_secret)を持つ。いまは追跡されているため、手元で書き換わった状態がgit add -uやgit commit -aでコミットへ入りうる。この Pull Request は、この設定を無視の一覧へ足し、追跡から外す。
.gitignore)へ 1 行足すgit rm --cachedで追跡から外す。手元のファイルは消えない.serena/project.yml(対象のプロジェクトの定義)は追跡したままにする。こちらは利用者ごとに変わらず、秘密も持たない履歴の秘密について
コミット済みの版に秘密は入っていない。 現在の
HEADの版を検査したところ、auth_secretの行は無く、一致したのは token の数え方の注釈だけだった。したがって履歴の書き換えは要らない。取り込んだ後にすること(利用者向け)
取り込むと、この設定は追跡されなくなる。手元で書き換えている場合、
git pullが「取り込みで上書きされる」と言って止まることがある。 その場合は控えを取ってから取り込む。Test plan
git check-ignore -v .serena/serena_config.ymlが.gitignore:54を指す)git status --shortがD .serena/serena_config.yml)工程
モードは
light(本番の振る舞いも本番コードの構造も変えない。静的な設定の変更)。実装レビュー(/ndf:cross-review)はこの Pull Request ではまだ通していない。🤖 Generated with Claude Code