Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,14 @@ on:
jobs:
release:
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
steps:
- name: Checkout code
uses: actions/checkout@v7
with:
fetch-depth: 0
token: ${{ secrets.GH_TOKEN }}
- name: Get tags
run: git fetch --tags origin
- name: Install Node Dependencies
Expand All @@ -29,15 +31,15 @@ jobs:
commit: 'Release new version'
version: npm run version
env:
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Create new release
if: steps.changesets.outputs.hasChangesets == 'false'
run: |
npx changeset tag && git push origin --tags
COMMIT_TAG=$(git tag --points-at HEAD)
if [ -n "$COMMIT_TAG" ]; then
echo "A tag is attached to HEAD. Creating a new release..."
echo "${{ secrets.GH_TOKEN }}" | gh auth login --with-token
echo "${{ secrets.GITHUB_TOKEN }}" | gh auth login --with-token
CHANGELOG=$(awk '
BEGIN { recording=0; }
/^## / {
Expand Down