-
-
Notifications
You must be signed in to change notification settings - Fork 306
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
meta: Add Pre Commit Hook #1946
Conversation
Add pre commit to call clang-format and a couple of other checks.
BTW, I think rbenv should be added to the Brewfile. I didn't have it installed for example, and it stopped |
* master: meta: Add Pre Commit Hook (#1946)
init: setup-git | ||
which brew || /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" | ||
brew bundle | ||
rbenv install --skip-existing | ||
rbenv exec gem update bundler | ||
rbenv exec bundle update | ||
cd Samples/TrendingMovies && carthage update --use-xcframeworks | ||
|
||
setup-git: | ||
ifneq (, $(shell which pre-commit)) | ||
pre-commit install |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This setup won't work on new systems. We need to add pre-commit
to Brewfile
, otherwise it'll never be installed, and setup-git
will never install the hooks. Also, I think it'd be better to avoid the dependency indirection and which
check, by putting pre-commit install
directly into make init
after brew bundle
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It got added to the Brewfile in #1947
* master: build: Remove trailing-whitespace (#1953) ci: Compile iOS13-Swift sample (#1951) release: 7.20.0 meta: Fix changelog (#1950) feat: Add sample rate in the baggage header, remove Userid and Transaction (#1936) build: Upate Brewfile.lock and Gemfile.lock (#1947) meta: Add Pre Commit Hook (#1946) ref: Remove unused SentryCrashDeadlock (#1941) feat: Add screenshot at crash (#1920) Add code docs for SentryScope (#1942)
Add pre-commit to call clang-format and a couple
of other checks.
#skip-changelog