Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

vcs_utils: fix git misuse for checking if local commit exists #92

Merged
merged 1 commit into from
Mar 20, 2025

Conversation

no92
Copy link
Member

@no92 no92 commented Mar 20, 2025

git rev-parse --verify does not check whether the commit exists locally, but rather whether the hash can be used to access the object database. We replace this by git branch --contains, which does exactly what it says on the tin.

`git rev-parse --verify` does not check whether the commit exists
locally, but rather whether the hash can be used to access the object
database. We replace this by `git branch --contains`, which does exactly
what it says on the tin.
Copy link
Member

@Dennisbonke Dennisbonke left a comment

Choose a reason for hiding this comment

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

LGTM

@no92 no92 merged commit f3fe8c5 into managarm:master Mar 20, 2025
3 checks passed
@no92 no92 deleted the local-commit-checking branch March 20, 2025 00:34
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.

2 participants