Skip to content

Commit

Permalink
ci: fix changelog checker by trimming the 'changelog/' prefix (#2368)
Browse files Browse the repository at this point in the history
  • Loading branch information
SteveLauC authored Apr 13, 2024
1 parent c179d7b commit 95d1285
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .github/actions/check_new_changelog/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,11 @@ runs:
NEW_CHANGELOGS: ${{ steps.new-changelogs.outputs.added_files }}
PR_NUMBER: ${{ github.event.number }}
run: |
# `cl` will be something like "changelog/1.added.md"
for cl in ${NEW_CHANGELOGS}; do
# Trim the directory name
prefix="changelog/"; trimmed_cl=${cl/#$prefix}; cl="${trimmed_cl}";
# parse it
IFS='.' read id kind file_extension <<< "${cl}"
Expand Down

0 comments on commit 95d1285

Please sign in to comment.