Skip to content

Commit

Permalink
Update updateChangelog.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
rcskosir authored Dec 13, 2024
1 parent 1ed3471 commit e2c5b14
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/updateChangelog.yml
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ jobs:
changelog_file="CHANGELOG.md"
# Extract the type (e.g., BUG or ENHANCEMENT) from the input string
if [[ "$input_string" =~ ^\[(BUG|ENHANCEMENT|FEATURE|BREAKING)\] ]]; then
if [[ $input_string =~ ^\[(BUG|ENHANCEMENT|FEATURE|BREAKING)\] ]]; then
change_type="${BASH_REMATCH[1]}"
else
echo "Invalid input string format. Expected '[BUG]' or '[ENHANCEMENT]' or '[FEATURE]' or '[BREAKING]'."
Expand All @@ -124,7 +124,7 @@ jobs:
input_string=$(echo $input_string | sed -e 's/^\[BUG\] //' -e 's/^\[ENHANCEMENT\] //' -e 's/^\[FEATURE\] //' -e 's/^\[BREAKING\] //')
# Find the header and insert the input string under the first occurrence
awk -v header=$header -v input_string=$input_string '
awk -v header="$header" -v input_string="$input_string" '
BEGIN {
found_header = 0
}
Expand All @@ -145,6 +145,6 @@ jobs:
echo "The change has been added to the changelog under the first occurrence of $header."
git add CHANGELOG.md
git commit -m 'Update changelog'
git commit -m "Update changelog"
git push --set-upstream origin automated-changelog

0 comments on commit e2c5b14

Please sign in to comment.