File tree Expand file tree Collapse file tree 2 files changed +26
-3
lines changed Expand file tree Collapse file tree 2 files changed +26
-3
lines changed Original file line number Diff line number Diff line change @@ -87,10 +87,12 @@ jobs:
87
87
with :
88
88
fetch-depth : 0
89
89
90
- # - name: Print debug output
90
+ # - name: Print debug output
91
91
# env:
92
92
# GITHUB_CONTEXT: ${{ toJson(github) }}
93
93
# run: |
94
+ # echo
95
+
94
96
# echo "$GITHUB_SHA"
95
97
# echo "$GITHUB_REF"
96
98
# echo "$GITHUB_HEAD_REF"
@@ -100,10 +102,13 @@ jobs:
100
102
101
103
- name : Check commit messages
102
104
env :
103
- BEFORE : ${{ github.event.push. before }}
105
+ BEFORE : ${{ github.event.before }}
104
106
# for a PR this will be: origin/master..origin/$GITHUB_HEAD_REF
105
107
# for a push it will be: $BEFORE..
106
108
run : |
109
+ echo A"$BEFORE"B
110
+ echo C"${BEFORE}"D
111
+ echo E"${BEFORE:-origin/master}"F
107
112
bin/commitlint ${BEFORE:-origin/master}..${GITHUB_HEAD_REF:+origin/$GITHUB_HEAD_REF}
108
113
109
114
# things to be cached/restored:
Original file line number Diff line number Diff line change @@ -50,11 +50,29 @@ jobs:
50
50
with :
51
51
fetch-depth : 0
52
52
53
+ # - name: Print debug output
54
+ # env:
55
+ # GITHUB_CONTEXT: ${{ toJson(github) }}
56
+ # run: |
57
+ # echo
58
+
59
+ # echo "$GITHUB_SHA"
60
+ # echo "$GITHUB_REF"
61
+ # echo "$GITHUB_HEAD_REF"
62
+ # echo "$GITHUB_BASE_REF"
63
+ # git log "$GITHUB_BASE_REF"..
64
+ # bin/commitlint "$GITHUB_BASE_REF"..
65
+
53
66
- name : Check commit messages
67
+ env :
68
+ BEFORE : ${{ github.event.before }}
54
69
# for a PR this will be: master..origin/$GITHUB_HEAD_REF
55
70
# for a push it will be: master..
56
71
run : |
57
- bin/commitlint origin/master..${GITHUB_HEAD_REF:+origin/$GITHUB_HEAD_REF}
72
+ echo A"$BEFORE"B
73
+ echo C"${BEFORE}"D
74
+ echo E"${BEFORE:-origin/master}"F
75
+ bin/commitlint ${BEFORE:-origin/master}..${GITHUB_HEAD_REF:+origin/$GITHUB_HEAD_REF}
58
76
59
77
# things to be cached/restored:
60
78
You can’t perform that action at this time.
0 commit comments