Skip to content

Commit

Permalink
chore: publish to npm
Browse files Browse the repository at this point in the history
  • Loading branch information
li-yechao committed Feb 29, 2024
1 parent e18dea1 commit a52bb75
Showing 1 changed file with 20 additions and 1 deletion.
21 changes: 20 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ on:
branches:
- master
tags:
- '*'
- "*"
env:
FORCE_COLOR: 1
concurrency:
Expand Down Expand Up @@ -151,3 +151,22 @@ jobs:
if: matrix.node == 16 && startsWith(github.ref, 'refs/tags/')
env:
NODE_PRE_GYP_GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
publish:
runs-on: ubuntu-latest

if: "! contains(toJSON(github.event.commits.*.message), '[skip ci]')"

steps:
- name: Checkout repo
uses: actions/checkout@v3

- name: Set yarn cache
uses: c-hive/gha-yarn-cache@v2

- name: Install dependencies
run: yarn

- name: Publish to NPM
run: |
npm config set '//registry.npmjs.org/:_authToken' "${{ secrets.NPM_TOKEN }}"
npm publish --access public --no-git-checks

0 comments on commit a52bb75

Please sign in to comment.