feat: add git publishing action
This commit is contained in:
parent
13f9939c6d
commit
13f748a2d7
4
.github/workflows/github-actions.yml
vendored
4
.github/workflows/github-actions.yml
vendored
@ -1,5 +1,7 @@
|
||||
name: Test
|
||||
run-name: ${{ github.actor }} 🚀
|
||||
run-name: Linting and typechecking 🚀
|
||||
env:
|
||||
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|
||||
on:
|
||||
push:
|
||||
pull_request:
|
||||
|
||||
20
.github/workflows/publishing.yml
vendored
Normal file
20
.github/workflows/publishing.yml
vendored
Normal file
@ -0,0 +1,20 @@
|
||||
name: Publish Package
|
||||
run-name: Publishing Package to npmjs registry
|
||||
env:
|
||||
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|
||||
on:
|
||||
release:
|
||||
types: [published]
|
||||
jobs:
|
||||
publishing:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: Use Node.js
|
||||
uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version-file: '.nvmrc'
|
||||
cache: 'yarn'
|
||||
registry-url: 'https://registry.npmjs.org'
|
||||
- run: yarn
|
||||
- run: yarn npm publish
|
||||
@ -1,3 +1,7 @@
|
||||
nodeLinker: node-modules
|
||||
|
||||
yarnPath: .yarn/releases/yarn-4.1.1.cjs
|
||||
|
||||
npmPublishRegistry: "https://registry.npmjs.org"
|
||||
|
||||
npmAuthToken: ${NODE_AUTH_TOKEN || ""}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user