Skip to content

Commit 30238ae

Browse files
authored
Create log-test.yml
1 parent 85c12ff commit 30238ae

File tree

1 file changed

+28
-0
lines changed

1 file changed

+28
-0
lines changed

.github/workflows/log-test.yml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: APK Release Draft
2+
3+
on:
4+
workflow_dispatch:
5+
6+
jobs:
7+
test-git-logs:
8+
runs-on: ubuntu-latest
9+
10+
steps:
11+
- name: Checkout code
12+
uses: actions/checkout@v3
13+
14+
- name: Get commit messages since last tag
15+
id: release_notes
16+
run: |
17+
git fetch --tags
18+
LAST_TAG=$(git describe --tags --abbrev=0 2>/dev/null || echo "")
19+
if [ -z "$LAST_TAG" ]; then
20+
git log --pretty=format:"- %s %h%n" > changelog.txt
21+
else
22+
git log ${LAST_TAG}..HEAD --pretty=format:"- %s %h%n" > changelog.txt
23+
fi
24+
25+
- name: print changelog
26+
run: cat changelog.txt
27+
28+

0 commit comments

Comments
 (0)