Add optional GPG signing status display in commits pane#5376
Add optional GPG signing status display in commits pane#5376Xyerophyte wants to merge 3 commits intojesseduffield:masterfrom
Conversation
Add a new gui.showGpgSigningStatus config option that, when enabled, shows GPG signature verification status for each commit in the commits view. Uses git's %G? format placeholder to display colored indicators: green check for valid signatures, red X for bad/revoked, yellow tilde for missing keys, and blue dash for unsigned commits. Disabled by default since GPG verification adds latency to commit loading. Closes jesseduffield#5363 Made-with: Cursor
There was a problem hiding this comment.
Pull request overview
Adds an optional gui.showGpgSigningStatus config option that displays a colored GPG signature verification indicator for each commit in the commits view.
Changes:
- New
ShowGpgSigningStatusconfig field (defaultfalse) with schema and docs - Conditional
%G?format in git log and parsing of GPG status field in commit loader - Colored GPG status indicator column in commit presentation
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| pkg/config/user_config.go | New ShowGpgSigningStatus bool config field |
| pkg/commands/models/commit.go | GpgStatus field added to Commit struct and NewCommitOpts |
| pkg/commands/git_commands/commit_loader.go | Conditional GPG format in log command and parsing of GPG field |
| pkg/gui/presentation/commits.go | Renders colored GPG status indicator column |
| schema-master/config.json | Schema entry for new config option |
| docs-master/Config.md | Documentation for new config option |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
You can also share your feedback on Copilot code review. Take the survey.
Up to standards ✅🟢 Issues
|
| Metric | Results |
|---|---|
| Complexity | 0 |
| Duplication | 10 |
TIP This summary will be updated as you push new changes. Give us feedback
Pass the GPG parsing mode explicitly so rebasing and sequencer commits keep their subject lines when signature status is enabled. Add regression tests for commit loading, TODO hydration, and commit row rendering.
|
Fixed the GPG-status follow-up regression in the commit loader.
I couldn't run or in this environment because is not installed on the machine, so CI or a local Go-enabled environment still needs to validate the change set. |
|
Follow-up: verification is still pending because this machine does not have the Go toolchain installed. The remaining checks are: go test ./... -short and go generate ./... . |
Summary
gui.showGpgSigningStatusconfig option (default:false) that shows GPG signature verification status for each commit in the commits viewcheck- valid signature (G/U)X- bad/revoked/expired signature (B/R/X/Y)~- missing signing key (E)-- unsigned commit (Nor empty)Closes #5363
Example config
Changes
GpgStatusfield toCommitstruct andNewCommitOptsprettyFormatWithGpgconstant using%G?format placeholder; conditionally selects format and parses the GPG field based on configShowGpgSigningStatus booltoGuiConfigwithfalsedefaultTest plan
showGpgSigningStatus: false(default): no change in behavior or performanceshowGpgSigningStatus: true: GPG status column is displayed with colored indicatorsMade with Cursor