From 79428e6297c8b3ea8ea41b9a95af70d7419e6a74 Mon Sep 17 00:00:00 2001 From: jaywcjlove <398188662@qq.com> Date: Wed, 20 Jul 2022 11:58:17 +0800 Subject: [PATCH] chore: update workflows config. --- .github/workflows/ci.yml | 30 +++++++++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7bcef2c..8551207 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -81,4 +81,32 @@ jobs: - uses: JS-DevTools/npm-publish@v1 with: token: ${{ secrets.NPM_TOKEN }} - package: ./package.json \ No newline at end of file + package: ./package.json + + outputs: + successful: ${{steps.create_tag.outputs.successful }} + + github-package: + runs-on: ubuntu-18.04 + needs: build-deploy + if: needs.build-deploy.outputs.successful + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-node@v3 + with: + node-version: 16 + registry-url: https://npm.pkg.github.com + scope: '@jaywcjlove' + + - run: npm install + - run: npm run build + + - name: Modify @wcj/date => @jaywcjlove/date + uses: jaywcjlove/github-action-package@main + with: + data: | + { "name": "@jaywcjlove/date" } + + - run: npm publish + env: + NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}} \ No newline at end of file