IS-11036 added workflow to create a release when the repo is tagged#68
IS-11036 added workflow to create a release when the repo is tagged#68
Conversation
There was a problem hiding this comment.
Pull request overview
This PR adds a new GitHub Actions workflow that automatically creates a GitHub release whenever a tag matching the pattern ui-kit-* is pushed to the repository. This automation is designed to streamline the release process for the Curity UI Kit monorepo by eliminating manual release creation steps.
Changes:
- Added a new workflow file
.github/workflows/release.ymlthat triggers on tags with theui-kit-*pattern - The workflow extracts the version from the tag name and creates a GitHub release with that version
- Configured permissions to allow writing releases to the repository
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 1 out of 1 changed files in this pull request and generated 5 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| - name: Create GitHub Release | ||
| uses: actions/create-release@v1 | ||
| with: | ||
| tag_name: ${{ github.ref_name }} | ||
| release_name: ${{ steps.extract_version.outputs.version }} | ||
| body: ${{ steps.changelog.outputs.changelog }} |
There was a problem hiding this comment.
actions/create-release@v1 requires authentication, but this step doesn't pass a token (e.g., env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}). Without it, the release creation will fail with an auth error. Add the required token environment variable (or switch to an action that accepts an explicit token: input).
| - name: Generate changelog from merged PRs | ||
| id: changelog | ||
| env: | ||
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
There was a problem hiding this comment.
This workflow sets GITHUB_TOKEN for the gh CLI, but elsewhere in this repo gh is authenticated via GH_TOKEN. To match the existing pattern (and avoid any CLI auth edge cases), set GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} for the changelog step.
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
| - name: Generate changelog from merged PRs | ||
| id: changelog | ||
| env: | ||
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
No description provided.