From 7141bd54a6acc6f4d55a11a64e657e8c1732451e Mon Sep 17 00:00:00 2001 From: Zakary Timson Date: Thu, 14 Dec 2023 03:51:26 +0000 Subject: [PATCH] Add npm/publish/action.yaml --- npm/publish/action.yaml | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 npm/publish/action.yaml diff --git a/npm/publish/action.yaml b/npm/publish/action.yaml new file mode 100644 index 0000000..c2e6dca --- /dev/null +++ b/npm/publish/action.yaml @@ -0,0 +1,33 @@ +name: NPM Publish +description: Push to registry + +inputs: + registry: + type: string + required: false + description: NPM registry FQDM + default: ${{github.server_url}} + owner: + type: string + required: false + description: Owner to publish to + default: ${{github.repository_owner}} + token: + type: string + required: false + description: Access Token + default: ${{secrets.DEPLOY_TOKEN}} + +runs: + using: composite + steps: + - name: Setup registry + run: | + echo "_authToken=${{inputs.token}}" > .npmrc + echo "registry=${{inputs.registry}}/api/packages/${{inputs.owner}}/npm/" >> .npmrc + shell: sh + + - name: Publish + uses: docker://node + with: + args: /bin/sh -c "npm publish"