diff --git a/.github/generate_changelog.sh b/.github/generate_changelog.sh index 0130be7..8356077 100755 --- a/.github/generate_changelog.sh +++ b/.github/generate_changelog.sh @@ -27,14 +27,14 @@ label_for() { } commits=$(git log ${range} --reverse --pretty='format:%s') -known_pattern="^(feat|fix|refactor|perf|docs|test|ci|build|chore): " +known_pattern="^(feat|fix|refactor|perf|docs|test|ci|build|chore)(\([^)]*\))?!?: " first_section=1 for type in $types other; do if [ "$type" = "other" ]; then entries=$(printf '%s\n' "$commits" | grep -v -E "$known_pattern" | sed 's/^/- /' || true) else - entries=$(printf '%s\n' "$commits" | grep -E "^${type}: " | sed -E "s/^${type}: /- /" || true) + entries=$(printf '%s\n' "$commits" | grep -E "^${type}(\([^)]*\))?!?: " | sed -E "s/^${type}(\([^)]*\))?!?: /- /" || true) fi [ -z "$entries" ] && continue