-
Notifications
You must be signed in to change notification settings - Fork 46
Fix changelog #1791
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix changelog #1791
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -61,6 +61,8 @@ jobs: | |
| uses: anthropics/claude-code-action@beta | ||
| with: | ||
| anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }} | ||
| github_token: ${{ secrets.GITHUB_TOKEN }} | ||
|
|
||
| direct_prompt: | | ||
| Generate a changelog entry for version ${{ steps.get_version.outputs.VERSION }} of the Cartridge Controller SDK. | ||
|
|
||
|
|
@@ -70,7 +72,7 @@ jobs: | |
|
|
||
| Analyze the git commit range: ${{ steps.commit_range.outputs.RANGE }} | ||
|
|
||
| Create a changelog entry in this format and save it to a file called new-changelog-entry.md: | ||
| Create a changelog entry in this format and update CHANGELOG.md: | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ✅ Excellent simplification: Changing from creating a separate file to directly updating CHANGELOG.md eliminates the need for complex bash scripting and reduces the chance of formatting errors. This is much more maintainable. |
||
|
|
||
| ## [${{ steps.get_version.outputs.VERSION }}] - $(date +%Y-%m-%d) | ||
|
|
||
|
|
@@ -93,62 +95,6 @@ jobs: | |
|
|
||
| allowed_tools: "Read,Write,Bash" | ||
|
|
||
| - name: Check if CHANGELOG.md exists | ||
| id: check_changelog | ||
| run: | | ||
| if [ -f "CHANGELOG.md" ]; then | ||
| echo "exists=true" >> $GITHUB_OUTPUT | ||
| else | ||
| echo "exists=false" >> $GITHUB_OUTPUT | ||
| fi | ||
|
|
||
| - name: Create or update CHANGELOG.md | ||
| run: | | ||
| if [ "${{ steps.check_changelog.outputs.exists }}" == "true" ]; then | ||
| # Insert new entry after the header | ||
| if [ -f "new-changelog-entry.md" ]; then | ||
| # Create a temporary file | ||
| touch temp-changelog.md | ||
|
|
||
| # Process the file line by line | ||
| header_found=false | ||
| first_version_found=false | ||
|
|
||
| while IFS= read -r line; do | ||
| if [[ "$line" =~ ^#[[:space:]]Changelog ]]; then | ||
| # Found the header | ||
| echo "$line" >> temp-changelog.md | ||
| echo "" >> temp-changelog.md | ||
| header_found=true | ||
| elif [[ "$header_found" == "true" && "$first_version_found" == "false" && "$line" =~ ^##[[:space:]]\[ ]]; then | ||
| # Found the first version entry, insert new content before it | ||
| cat new-changelog-entry.md >> temp-changelog.md | ||
| echo "" >> temp-changelog.md | ||
| echo "$line" >> temp-changelog.md | ||
| first_version_found=true | ||
| else | ||
| # Copy all other lines as-is | ||
| echo "$line" >> temp-changelog.md | ||
| fi | ||
| done < CHANGELOG.md | ||
|
|
||
| # If no version entries were found (empty changelog), append the new entry | ||
| if [[ "$first_version_found" == "false" && "$header_found" == "true" ]]; then | ||
| cat new-changelog-entry.md >> temp-changelog.md | ||
| fi | ||
|
|
||
| # Replace the original file | ||
| mv temp-changelog.md CHANGELOG.md | ||
| fi | ||
| else | ||
| # Create new CHANGELOG.md | ||
| echo "# Changelog" > CHANGELOG.md | ||
| echo "" >> CHANGELOG.md | ||
| if [ -f "new-changelog-entry.md" ]; then | ||
| cat new-changelog-entry.md >> CHANGELOG.md | ||
| fi | ||
| fi | ||
|
|
||
| - name: Commit changelog changes | ||
| run: | | ||
| git config --local user.email "action@github.com" | ||
|
|
@@ -160,7 +106,3 @@ jobs: | |
| git commit -m "Generate changelog for v${{ steps.get_version.outputs.VERSION }}" | ||
| git push | ||
| fi | ||
|
|
||
| - name: Clean up temporary files | ||
| run: | | ||
| rm -f new-changelog-entry.md | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,22 +1,23 @@ | ||
| # Changelog | ||
|
|
||
| ## [0.8.0-alpha.0] - 2025-06-24 | ||
| ## [0.8.0] - 2025-06-24 | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ✅ Version update: Changed from |
||
|
|
||
| ### ✨ New Features | ||
| - **Session Management**: Added comprehensive session management functionality enabling secure session handling, registration, and consent flows for improved gaming UX (#1722) | ||
| - **Controller Interface Simplification**: Streamlined the main Controller interface with improved defaults and better developer experience (#1759) | ||
|
|
||
| ### 🚀 Improvements | ||
| ### 🚀 Improvements | ||
| - **@cartridge/controller**: Refactored WalletConnect implementation in preparation for multiple signers support (#1780) | ||
| - **@cartridge/controller**: Improved chain precedence logic to prioritize cartridgeChains over provided chains (#1769) | ||
| - **CI/CD**: Enhanced release automation with GitHub releases creation (#1782) and job summaries (#1784) | ||
| - **CI/CD**: Added automated changelog generation workflows (#1786) | ||
| - **CI/CD**: Added automated changelog generation workflows (#1786) and simplified release workflow (#1789) | ||
| - **Development**: Added Claude Code integration and workflow improvements for better collaboration (#1768, #1766) | ||
|
|
||
| ### 🐛 Bug Fixes | ||
| - **@cartridge/profile**: Fixed decimal formatting for credits balance display (#1781) | ||
| - **@cartridge/controller**: Fixed Discord integration bug that occurred when no wallet session exists (#1762) | ||
| - **Documentation**: Resolved doc-sync injection issues and improved sync reliability (#1764, #1765) | ||
| - **CI/CD**: Fixed changelog generation and multi-line output issues in release workflows (#1788) | ||
|
|
||
| ### ⚠️ Breaking Changes | ||
| - **Controller Interface**: The Controller interface has been simplified, which may require updates to existing integrations. Refer to the updated examples for migration guidance (#1759) | ||
|
|
||
This file was deleted.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ Good addition: Adding the
github_tokenparameter is important for the action to have proper permissions to update the repository. This was likely missing from the original implementation.