diff --git a/.github/workflows/publish-gpr.yml b/.github/workflows/publish-gpr.yml new file mode 100644 index 0000000..b62b803 --- /dev/null +++ b/.github/workflows/publish-gpr.yml @@ -0,0 +1,19 @@ +name: Publish GPR +on: + release: + types: [created] +jobs: + publish-gpr: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-node@v1 + with: + node-version: 12 + registry-url: https://npm.pkg.github.com/ + scope: '@ns0m' + - run: npm ci + - run: echo registry=https://npm.pkg.github.com/ns0m >> .npmrc + - run: npm publish + env: + NODE_AUTH_TOKEN: ${{secrets.GPR_TOKEN}} diff --git a/.github/workflows/publish-npm.yml b/.github/workflows/publish-npm.yml new file mode 100644 index 0000000..74672ae --- /dev/null +++ b/.github/workflows/publish-npm.yml @@ -0,0 +1,17 @@ +name: Publish NPM +on: + release: + types: [created] +jobs: + publish-npm: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-node@v1 + with: + node-version: 12 + registry-url: https://registry.npmjs.org/ + - run: npm ci + - run: npm publish --access public + env: + NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} diff --git a/.npmignore b/.npmignore new file mode 100644 index 0000000..bb0224d --- /dev/null +++ b/.npmignore @@ -0,0 +1 @@ +.github/