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

chore: add first pre-commit hook to check tool versions #4374

Merged
merged 2 commits into from
Oct 1, 2024

Conversation

armcknight
Copy link
Member

Check the installed version of clang-format and swiftlint and fail fast from the pre-commit run if they don't match what's in the homebrew lockfile. This approach could be extended to e.g. Gemfile.lock as well if desired.

We previously wanted to go the other way on this in #3739. But I still ran into local issues with mismatched lint/format rules dirtying unmodified files, so that didn't fix the root issue. I think this is the better solution than just not tracking the lockfiles.

#skip-changelog

Copy link
Member

@philipphofmann philipphofmann left a comment

Choose a reason for hiding this comment

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

Thanks @armcknight 💯

Makefile Outdated Show resolved Hide resolved
Copy link
Member

@philipphofmann philipphofmann left a comment

Choose a reason for hiding this comment

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

Thanks for the resolution message.

@armcknight armcknight merged commit 81c2187 into main Oct 1, 2024
7 checks passed
@armcknight armcknight deleted the armcknight/precommit-check-devenv-versions branch October 1, 2024 00:50
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