Skip to content

Commit 196e224

Browse files
committed
add CHANGELOG items to release notes
1 parent 83f6a3d commit 196e224

File tree

1 file changed

+22
-3
lines changed

1 file changed

+22
-3
lines changed

.github/workflows/release-build.yml

Lines changed: 22 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -395,19 +395,38 @@ jobs:
395395
print('\n'.join(formatted_deps))
396396
")
397397
398+
# Extract CHANGELOG entries for this version
399+
CHANGELOG_ENTRIES=$(python3 -c "
400+
import re
401+
with open('CHANGELOG.md', 'r') as f:
402+
content = f.read()
403+
version_pattern = r'## v${{ github.event.inputs.version }}.*?\n(.*?)(?=\n## |\Z)'
404+
version_match = re.search(version_pattern, content, re.DOTALL)
405+
if version_match:
406+
entries = version_match.group(1).strip()
407+
if entries:
408+
print(entries)
409+
")
410+
398411
# Create release notes
399412
cat > release_notes.md << EOF
400-
This release contains the following upstream components:
413+
$(if [ -n "$CHANGELOG_ENTRIES" ]; then echo "## What's Changed"; echo "$CHANGELOG_ENTRIES"; echo ""; fi)
414+
415+
## Upstream Components
401416
402417
$DEPS
403418
404-
This release also publishes to public ECR and PyPi.
419+
## Release Artifacts
420+
421+
This release publishes to public ECR and PyPi.
405422
* See ADOT Python auto-instrumentation Docker image v${{ github.event.inputs.version }} in our public ECR repository:
406423
https://gallery.ecr.aws/aws-observability/adot-autoinstrumentation-python
407424
* See version ${{ github.event.inputs.version }} in our PyPi repository:
408425
https://pypi.org/project/aws-opentelemetry-distro/
409426
410-
This release also includes the AWS OpenTelemetry Lambda Layer for Python version ${{ github.event.inputs.version }}-$(echo $GITHUB_SHA | cut -c1-7).
427+
## Lambda Layer
428+
429+
This release includes the AWS OpenTelemetry Lambda Layer for Python version ${{ github.event.inputs.version }}-$(echo $GITHUB_SHA | cut -c1-7).
411430
412431
Lambda Layer ARNs:
413432
${{ needs.generate-lambda-release-note.outputs.layer-note }}

0 commit comments

Comments
 (0)