Skip to content

Commit

Permalink
feat(version) 🔖 release 0.0.22 version
Browse files Browse the repository at this point in the history
  • Loading branch information
gokhangunduz committed Jul 29, 2024
1 parent ac0ecc9 commit 545e40a
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 43 deletions.
63 changes: 21 additions & 42 deletions .github/workflows/npm-publish.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Publish Package
name: Node.js Package

on:
push:
Expand All @@ -8,62 +8,41 @@ on:
jobs:
build:
runs-on: ubuntu-latest

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

- name: Set up Node.js
uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v3
with:
node-version: latest

- name: Install dependencies
run: npm install

- name: Build project
run: npm run build
- run: npm install

publish-npm:
runs-on: ubuntu-latest
needs: build

runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3

- name: Set up Node.js
uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v3
with:
node-version: latest

- name: Set npm package name
run: |
jq '.name = "hookstorm"' package.json > temp.json && mv temp.json package.json
- name: Publish npm package
run: npm publish
registry-url: https://registry.npmjs.org/
- run: npm run build
- run: npm publish
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

publish-github:
runs-on: ubuntu-latest
publish-gpr:
needs: build

runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- name: Checkout code
uses: actions/checkout@v3

- name: Set up Node.js
uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v3
with:
node-version: latest

- name: Set GitHub package name
run: |
jq '.name = "@gokhangunduz/hookstorm"' package.json > temp.json && mv temp.json package.json
- name: Publish GitHub package
run: npm publish --registry=https://npm.pkg.github.com/
registry-url: https://npm.pkg.github.com/
- run: jq '.name = "@gokhangunduz/hookstorm"' package.json > tmp.json && mv tmp.json package.json
- run: npm run build
- run: npm publish
env:
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "hookstorm",
"version": "0.0.21",
"version": "0.0.22",
"description": "hookstorm",
"main": "./dist/cjs/index.js",
"module": "./dist/esm/index.js",
Expand Down

0 comments on commit 545e40a

Please sign in to comment.