HeadlinesBriefing favicon HeadlinesBriefing.com

Claude Code Session URLs Polluting Git History Without Opt-In

Hacker News •
×

Claude Code automatically appends session URLs to every commit message and PR description, polluting git history without user consent. The feature is opt-out by default, meaning developers only discover it after commits are already pushed. A one-time onboarding prompt asking users to enable session URL attribution would provide a better user experience than the current hidden setting. While a .claude/settings.json option exists to suppress the URLs, it remains completely undiscovered by the average user. Similarly, commit-msg git hooks can strip the attribution but do not always fire reliably in remote or cloud environments. The proposal suggests making session URL attribution opt-in during onboarding, allowing users to explicitly enable the feature if desired rather than having it forced upon them. This change would prevent the unprofessional appearance and cluttering of commit history that currently occurs when developers are unaware the URLs are being added to their work.

The attribution.commit: "" setting in .claude/settings.json can suppress it, but it's completely undiscovered. A commit-msg git hook can also strip it, but it doesn't always fire reliably in remote/cloud environments.