Conversation
Contributor
Author
|
@gramster 👋 This repository doesn't have Copilot instructions. With Copilot instructions, I can understand the repository better, work faster and produce higher quality PRs. I can generate a .github/copilot-instructions.md file for you automatically. Click here to open a pre-filled issue and assign it to me. I'll write the instructions, and then tag you for review. |
- Add commit hash as "commit" field in blame properties - Update tests to expect commit hash in output - Update README documentation with new commit field - Add commit shortcut to filtering table - Verify functionality with manual testing Co-authored-by: gramster <2762632+gramster@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Feature request: expose commit hash from sarif blame
Expose commit hash in sarif blame output
Aug 29, 2025
gramster
approved these changes
Aug 29, 2025
rchiodo
approved these changes
Aug 29, 2025
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.
The
sarif blamecommand now includes the commit hash/SHA in the blame information output. Previously, while the blame functionality extracted commit hashes fromgit blame --porcelain, it only exposed author information, timestamps, and commit messages without the actual commit identifier.The commit hash is now available as a
commitfield in the blame properties:{ "properties": { "blame": { "commit": "915da616c17784840dd6b63e58aea0503e451264", "author": "Test User", "author-mail": "<test@example.com>", "author-time": "1756489481", "author-tz": "+0000", "committer": "Test User", "committer-mail": "<test@example.com>", "committer-time": "1756489481", "committer-tz": "+0000", "summary": "Fix file format", "filename": "test.py" } } }This change also adds a
commitfiltering shortcut that maps toproperties.blame.commitfor easier filtering by commit hash.The implementation is minimal and preserves all existing functionality while adding the requested commit hash information that was already being extracted internally.
Fixes #99.
💬 Share your feedback on Copilot coding agent for the chance to win a $200 gift card! Click here to start the survey.