File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : Changelog
2+
3+ # Controls when the workflow will run
4+ on :
5+ pull_request :
6+ branches : [ master ]
7+
8+ # Allows you to run this workflow manually from the Actions tab
9+ workflow_dispatch :
10+
11+
12+ jobs :
13+ changelog :
14+ runs-on : ubuntu-latest
15+
16+ steps :
17+ - uses : actions/checkout@v4
18+ with :
19+ fetch-depth : 0
20+
21+ - name : Check if CHANGELOG.md was modified
22+ run : |
23+ git fetch origin ${{ github.base_ref }}
24+ CHANGED_FILES=$(git diff --name-only origin/${{ github.base_ref }}...HEAD)
25+
26+ echo "$CHANGED_FILES"
27+
28+ if ! echo "$CHANGED_FILES" | grep -q "^CHANGELOG.md$"; then
29+ echo "❌ CHANGELOG.md was not changed in Pull Request!"
30+ exit 1
31+ fi
32+
33+ echo "✅ CHANGELOG.md was updated."
Original file line number Diff line number Diff line change 1010 # Allows you to run this workflow manually from the Actions tab
1111 workflow_dispatch :
1212
13-
1413jobs :
15- changelog :
16- runs-on : ubuntu-latest
17-
18- steps :
19- - uses : actions/checkout@v4
20- with :
21- fetch-depth : 0
22-
23- - name : Check if CHANGELOG.md was modified
24- run : |
25- git fetch origin ${{ github.base_ref }}
26- CHANGED_FILES=$(git diff --name-only origin/${{ github.base_ref }}...HEAD)
27-
28- echo "$CHANGED_FILES"
29-
30- if ! echo "$CHANGED_FILES" | grep -q "^CHANGELOG.md$"; then
31- echo "❌ CHANGELOG.md was not changed in Pull Request!"
32- exit 1
33- fi
34-
35- echo "✅ CHANGELOG.md was updated."
36-
3714 check :
3815 runs-on : ubuntu-22.04
3916
Original file line number Diff line number Diff line change 11## Changes
22
33
4+ ## 1.0.33
5+
6+ Fix GitHub Action for changelog verification job
7+
48## 1.0.32
59
610Add [ CHANGELOG.md] ( ./CHANGELOG.md )
You can’t perform that action at this time.
0 commit comments