From 8d80e74bee8654cba5f287c57aad271c6bd0f02e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Donny/=EA=B0=95=EB=8F=99=EC=9C=A4?= Date: Sat, 29 Jun 2024 18:55:06 +0900 Subject: [PATCH] chore(ci): Configure autopublish (#45) --- .github/workflows/publish.yml | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 .github/workflows/publish.yml diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml new file mode 100644 index 0000000..4b29c28 --- /dev/null +++ b/.github/workflows/publish.yml @@ -0,0 +1,35 @@ +name: Publish (npm) + +on: + push: + branches: + - main + - ci + +env: + CI: 1 + +jobs: + publish-npm: + name: Publish to npm + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - name: Setup node + uses: actions/setup-node@v2 + with: + node-version: 20 + + - run: | + corepack enable + pnpm i + + - name: Create Release Pull Request or Publish to npm + id: changesets + uses: changesets/action@v1 + with: + publish: pnpm publish -r --access public + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + NPM_TOKEN: ${{ secrets.NPM_TOKEN }}