Skip to content

Add optional GPG signing status display in commits pane#5376

Open
Xyerophyte wants to merge 3 commits intojesseduffield:masterfrom
Xyerophyte:feature/gpg-signing-status
Open

Add optional GPG signing status display in commits pane#5376
Xyerophyte wants to merge 3 commits intojesseduffield:masterfrom
Xyerophyte:feature/gpg-signing-status

Conversation

@Xyerophyte
Copy link
Copy Markdown

Summary

  • Adds a new gui.showGpgSigningStatus config option (default: false) that shows GPG signature verification status for each commit in the commits view
  • When enabled, a colored indicator column appears after the commit hash:
    • Green check - valid signature (G/U)
    • Red X - bad/revoked/expired signature (B/R/X/Y)
    • Yellow ~ - missing signing key (E)
    • Blue - - unsigned commit (N or empty)
  • Disabled by default since GPG verification adds latency to commit loading

Closes #5363

Example config

gui:
  showGpgSigningStatus: true

Changes

  • pkg/commands/models/commit.go: Added GpgStatus field to Commit struct and NewCommitOpts
  • pkg/commands/git_commands/commit_loader.go: Added prettyFormatWithGpg constant using %G? format placeholder; conditionally selects format and parses the GPG field based on config
  • pkg/config/user_config.go: Added ShowGpgSigningStatus bool to GuiConfig with false default
  • pkg/gui/presentation/commits.go: Renders a colored GPG status indicator column between the commit hash and bisect columns
  • schema-master/config.json: Added schema entry for the new config option
  • docs-master/Config.md: Added documentation for the new config option

Test plan

  • When showGpgSigningStatus: false (default): no change in behavior or performance
  • When showGpgSigningStatus: true: GPG status column is displayed with colored indicators
  • CI validates auto-generated schema and docs

Made with Cursor

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
Copilot AI review requested due to automatic review settings March 14, 2026 23:17
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

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 ShowGpgSigningStatus config field (default false) 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.

@codacy-production
Copy link
Copy Markdown

codacy-production bot commented Apr 12, 2026

Up to standards ✅

🟢 Issues 0 issues

Results:
0 new issues

View in Codacy

🟢 Metrics 0 complexity · 10 duplication

Metric Results
Complexity 0
Duplication 10

View in Codacy

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.
@Xyerophyte
Copy link
Copy Markdown
Author

Fixed the GPG-status follow-up regression in the commit loader.

  • pass the GPG parsing mode explicitly when reading log lines
  • use the GPG-aware pretty format when hydrating rebase/sequencer commits
  • add regression coverage for commit loading, TODO hydration, and commits-pane rendering

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.

@Xyerophyte
Copy link
Copy Markdown
Author

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 ./... .

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.

show gpg signing status in the commits pane

2 participants