Skip to content

Commit

Permalink
🪐 commit
Browse files Browse the repository at this point in the history
  • Loading branch information
antonymott committed Dec 3, 2024
1 parent a6c7e3d commit afbc58d
Showing 1 changed file with 19 additions and 14 deletions.
33 changes: 19 additions & 14 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@ name: Publish
on:
push:
branches:
- '**'
# - main
# - '**'
- main


# concurrency: ${{ github.workflow }}-${{ github.ref }}
concurrency: ${{ github.workflow }}-${{ github.ref }}

permissions:
contents: write
Expand Down Expand Up @@ -34,6 +34,9 @@ jobs:
registry-url: 'https://registry.npmjs.org'
cache: 'pnpm'

- name: Linting typescript
run: pnpm lint

- name: Test
run: pnpm test

Expand Down Expand Up @@ -63,15 +66,17 @@ jobs:

- name: Publish
if: steps.check.outputs.version_changed == 'true'
run: npm publish --access public
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
id: changesets
uses: changesets/action@v1
# run: npm publish --access public
# env:
# NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
# # GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Tag release
if: steps.check.outputs.version_changed == 'true'
run: |
git config --local user.email "github-actions[bot]@users.noreply.github.com"
git config --local user.name "github-actions[bot]"
git tag -a "v${{ steps.check.outputs.new_version }}" -m "v${{ steps.check.outputs.new_version }}"
git push origin "v${{ steps.check.outputs.new_version }}"
# - name: Tag release
# if: steps.check.outputs.version_changed == 'true'
# run: |
# git config --local user.email "github-actions[bot]@users.noreply.github.com"
# git config --local user.name "github-actions[bot]"
# git tag -a "v${{ steps.check.outputs.new_version }}" -m "v${{ steps.check.outputs.new_version }}"
# git push origin "v${{ steps.check.outputs.new_version }}"

0 comments on commit afbc58d

Please sign in to comment.