Skip to content
/ utils Public

Hide Git commit sign message#632

Merged
5ouma merged 3 commits intomainfrom
fix-pre-commit-git-commit-sign
Jan 8, 2026
Merged

Hide Git commit sign message#632
5ouma merged 3 commits intomainfrom
fix-pre-commit-git-commit-sign

Conversation

@5ouma
Copy link
Owner

@5ouma 5ouma commented Jan 8, 2026

It will break the commit hash get logic.

It will break commit hash get logic.
Copilot AI review requested due to automatic review settings January 8, 2026 09:51
@github-actions github-actions bot added the 🚸 pre-commit Check the code with pre-commit hooks label Jan 8, 2026
Copy link

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

This PR fixes an issue where Git commit signature verification messages interfere with parsing commit hashes in the upload-git-commit-notion pre-commit hook script. The fix adds a git configuration parameter to suppress signature display when retrieving commit hashes.

  • Adds -c log.showSignature=false flag to the git log command to hide signature verification output

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@coderabbitai
Copy link

coderabbitai bot commented Jan 8, 2026

Walkthrough

Modified the git log invocation in a script to suppress signature verification output by adding the -c log.showSignature=false configuration flag. The rest of the command behavior, including format specifiers and Notion posting pipeline, remains unchanged.

Changes

Cohort / File(s) Summary
Git signature output suppression
pre-commit/scripts/upload-git-commit-notion
Added -c log.showSignature=false flag to git log command to suppress signature verification output in the loop iteration

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately describes the main change: suppressing Git commit signature verification output in the git log command.
Description check ✅ Passed The description explains the problem being addressed: a Git commit sign message breaks the commit hash retrieval logic, which directly relates to the changeset.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch fix-pre-commit-git-commit-sign

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

🧹 Nitpick comments (1)
pre-commit/scripts/upload-git-commit-notion (1)

42-42: Apply -c log.showSignature=false consistently to all git log commands for robustness.

Lines 17-19 should also include the -c log.showSignature=false flag alongside line 42 for consistency. While the impact only manifests with GPG-signed commits (which are not present in the current repository), applying the flag uniformly ensures the script extracts clean data regardless of signature configuration. This prevents potential JSON corruption if message, description, or date fields are contaminated by signature output.

📜 Review details

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 1183d9a and 8dcf578.

📒 Files selected for processing (1)
  • pre-commit/scripts/upload-git-commit-notion
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
  • GitHub Check: Upload results
  • GitHub Check: 🚸 pre-commit

@5ouma 5ouma merged commit 68601ad into main Jan 8, 2026
5 checks passed
@5ouma 5ouma deleted the fix-pre-commit-git-commit-sign branch January 8, 2026 10:02
@5ouma 5ouma bot mentioned this pull request Jan 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🚸 pre-commit Check the code with pre-commit hooks

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants