Skip to content

Commit d979337

Browse files
author
Manus Sandbox
committed
fix: Simplify release workflow using environment variables
- Remove heredoc approach that caused YAML parsing issues - Use environment variables for GitHub Actions expressions - Use echo commands to build release notes file - Should fix workflow syntax errors
1 parent b265780 commit d979337

1 file changed

Lines changed: 29 additions & 28 deletions

File tree

.github/workflows/release.yml

Lines changed: 29 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,9 @@ jobs:
3030
3131
- name: Generate changelog
3232
id: changelog
33+
env:
34+
TAG_NAME: ${{ steps.version.outputs.tag }}
35+
REPO_NAME: ${{ github.repository }}
3336
run: |
3437
# Get previous tag
3538
PREV_TAG=$(git describe --tags --abbrev=0 HEAD^ 2>/dev/null || echo "")
@@ -43,35 +46,33 @@ jobs:
4346
COMMITS=$(git log ${PREV_TAG}..HEAD --pretty=format:"- %s (%h)" --reverse)
4447
fi
4548
46-
# Create changelog content using heredoc to avoid YAML escaping issues
47-
cat > release-notes.md << 'RELEASE_NOTES_EOF'
48-
## What's New in ${{ steps.version.outputs.tag }} 🚀
49-
50-
### Changes
51-
RELEASE_NOTES_EOF
52-
echo "$COMMITS" >> release-notes.md
53-
cat >> release-notes.md << 'RELEASE_NOTES_EOF'
54-
55-
---
56-
57-
## Full Changelog
58-
See [CHANGELOG.md](https://github.com/${{ github.repository }}/blob/main/CHANGELOG.md) for complete version history.
59-
60-
## Installation
61-
```bash
62-
git clone https://github.com/${{ github.repository }}.git
63-
cd data-normalization-platform
64-
pnpm install
65-
pnpm run dev
66-
```
67-
68-
## Documentation
69-
- [README.md](https://github.com/${{ github.repository }}/blob/main/README.md)
70-
- [VERSION_HISTORY.md](https://github.com/${{ github.repository }}/blob/main/VERSION_HISTORY.md)
71-
- [API Documentation](https://github.com/${{ github.repository }}/blob/main/API_DOCUMENTATION.md)
72-
RELEASE_NOTES_EOF
49+
# Create release notes file
50+
{
51+
echo "## What's New in ${TAG_NAME} 🚀"
52+
echo ""
53+
echo "### Changes"
54+
echo "$COMMITS"
55+
echo ""
56+
echo "---"
57+
echo ""
58+
echo "## Full Changelog"
59+
echo "See [CHANGELOG.md](https://github.com/${REPO_NAME}/blob/main/CHANGELOG.md) for complete version history."
60+
echo ""
61+
echo "## Installation"
62+
echo '```bash'
63+
echo "git clone https://github.com/${REPO_NAME}.git"
64+
echo "cd data-normalization-platform"
65+
echo "pnpm install"
66+
echo "pnpm run dev"
67+
echo '```'
68+
echo ""
69+
echo "## Documentation"
70+
echo "- [README.md](https://github.com/${REPO_NAME}/blob/main/README.md)"
71+
echo "- [VERSION_HISTORY.md](https://github.com/${REPO_NAME}/blob/main/VERSION_HISTORY.md)"
72+
echo "- [API Documentation](https://github.com/${REPO_NAME}/blob/main/API_DOCUMENTATION.md)"
73+
} > release-notes.md
7374
74-
echo "Generated changelog for ${{ steps.version.outputs.tag }}"
75+
echo "Generated changelog for ${TAG_NAME}"
7576
7677
- name: Create GitHub Release
7778
uses: softprops/action-gh-release@v1

0 commit comments

Comments
 (0)