Skip to content

Commit

Permalink
added workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
AlemTuzlak committed Oct 5, 2024
1 parent 72fcb24 commit be02359
Show file tree
Hide file tree
Showing 3 changed files with 45 additions and 2 deletions.
24 changes: 24 additions & 0 deletions .github/publish-commit.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: 🚀 pkg-pr-new
on: [push, pull_request]

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v2

- run: corepack enable
- uses: actions/setup-node@v4
with:
node-version: 20
cache: "npm"

- name: Install dependencies
run: npm install

- name: Build
run: npm run build

- run: npx pkg-pr-new publish
19 changes: 19 additions & 0 deletions .github/publish.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: Publish Package to npmjs
on:
release:
types: [published]
workflow_dispatch:
jobs:
npm-publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
# Setup .npmrc file to publish to npm
- uses: actions/setup-node@v4
with:
node-version: "20.x"
registry-url: "https://registry.npmjs.org"
- run: npm ci
- run: npm publish
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit be02359

Please sign in to comment.