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:
108108 - name : Checkout source
109109 uses : actions/checkout@v3
110110 with :
111- ref : ${{ github.event.pull_request.head.sha }}
111+ fetch-depth : 0 # Fetch all the history of PR commits
112112
113113 - name : Setup Python
114114 uses : actions/setup-python@v3
@@ -121,8 +121,8 @@ jobs:
121121
122122 - name : Run Commitlint
123123 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
126126 pre-commit run commitlint --hook-stage commit-msg --commit-msg-file .git/COMMIT_EDITMSG
127127
128128 build-images :
You can’t perform that action at this time.
0 commit comments