Skip to content

Commit

Permalink
ci:优化 ChangeLog 消息格式
Browse files Browse the repository at this point in the history
- 使用 sed命令将多行 commit message转换为单行,解决格式问题
- 确保在推送事件中生成正确的 ChangeLog 消息
  • Loading branch information
lt-name committed Feb 17, 2025
1 parent 3b1e83c commit 43bc327
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/maven.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ jobs:
- name: Format ChangeLog
id: get-changelog
if: success() && github.event_name == 'push' && github.repository == 'MemoriesOfTime/EconomyAPI' && contains(github.ref_name, 'master')
run: echo "changelog=${{ github.event.commits[0].message }}" >> $GITHUB_OUTPUT
run: echo "changelog=$(echo '${{ github.event.commits[0].message }}' | sed ':a;N;$!ba;s/\n/\\n/g')" >> $GITHUB_OUTPUT
- name: Get Time
id: time
uses: nanzm/[email protected]
Expand Down

0 comments on commit 43bc327

Please sign in to comment.