File tree Expand file tree Collapse file tree 1 file changed +13
-2
lines changed Expand file tree Collapse file tree 1 file changed +13
-2
lines changed Original file line number Diff line number Diff line change @@ -106,12 +106,23 @@ jobs:
106106 steps :
107107 - name : Checkout source
108108 uses : actions/checkout@v3
109+ with :
110+ ref : ${{ github.event.pull_request.head.sha }}
109111
110112 - name : Setup Python
111113 uses : actions/setup-python@v3
112114
113- - name : Setup Pre-Commit
114- uses :
pre-commit/[email protected] 115+ - name : Setup Pre-commit
116+ run : pip install pre-commit
117+
118+ - name : Run Pre-commit
119+ run : pre-commit run --all-files
120+
121+ - name : Run Commitlint
122+ run : |
123+ COMMIT_MSG=$(git log -1 --pretty=%B)
124+ echo "$COMMIT_MSG" > .git/COMMIT_EDITMSG
125+ pre-commit run commitlint --hook-stage commit-msg --commit-msg-file .git/COMMIT_EDITMSG
115126
116127 build-images :
117128 runs-on : ubuntu-latest
You can’t perform that action at this time.
0 commit comments