File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -108,7 +108,7 @@ jobs:
108
108
- name : Checkout source
109
109
uses : actions/checkout@v3
110
110
with :
111
- ref : ${{ github.event.pull_request.head.sha }}
111
+ fetch-depth : 0 # Fetch all the history of PR commits
112
112
113
113
- name : Setup Python
114
114
uses : actions/setup-python@v3
@@ -121,8 +121,8 @@ jobs:
121
121
122
122
- name : Run Commitlint
123
123
run : |
124
- COMMIT_MSG=$(git log -1 --pretty=%B)
125
- echo "$COMMIT_MSG" > .git/COMMIT_EDITMSG
124
+ # Get all the commits between the base and head refs
125
+ git log --pretty=%B ${{ github.event.pull_request.base.sha }}..${{ github.event.pull_request.head.sha }} | tee .git/COMMIT_EDITMSG
126
126
pre-commit run commitlint --hook-stage commit-msg --commit-msg-file .git/COMMIT_EDITMSG
127
127
128
128
build-images :
You can’t perform that action at this time.
0 commit comments