Skip to content

Commit

Permalink
fix: only checks the commits from the current PR
Browse files Browse the repository at this point in the history
  • Loading branch information
Azhovan committed Sep 7, 2023
1 parent a3c9f97 commit 554a443
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion make/pre-commit.mk
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,6 @@ ifeq ($(wildcard $(PRE_COMMIT_CONFIG_FILE)),)
$(error Cannot find pre-commit config file $(PRE_COMMIT_CONFIG_FILE). Specify the config file via PRE_COMMIT_CONFIG_FILE variable)
endif
env SKIP=$(SKIP) pre-commit run -a --show-diff-on-failure --config $(PRE_COMMIT_CONFIG_FILE)
git fetch origin main && gitlint --ignore-stdin --commits origin/main..HEAD
git fetch origin main
merge_base=$(git merge-base HEAD origin/main)
gitlint --ignore-stdin --commits ${merge_base}..HEAD

0 comments on commit 554a443

Please sign in to comment.