Skip to content

Commit

Permalink
ci: add github actions
Browse files Browse the repository at this point in the history
  • Loading branch information
mochatek committed May 26, 2024
1 parent 8a54806 commit ba0bdb7
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 1 deletion.
30 changes: 30 additions & 0 deletions .github/publish-to-npm.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# This workflow will build the publish the jsonarrayfs package to NPM when a version-tagged commit is pushed

name: Publish jsonarrayfs library to NPM

on:
push:
tags:
- "v[0-9]+.[0-9]+.[0-9]+"

permissions:
contents: read

jobs:
build-and-publish:
name: Build dist from source and publish the artifacts to NPM
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@master
- name: Setup Node.js
uses: actions/setup-node@v2
with:
node-version: "18.x"
registry-url: "https://registry.npmjs.org"
- name: Install dependencies and build
run: npm ci && npm run build
- name: Publish package to NPM
run: npm publish
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@
"stream",
"json array",
"chunk",
"batch"
"batch",
"append json"
],
"author": "Akash S Panickar",
"license": "MIT",
Expand Down

0 comments on commit ba0bdb7

Please sign in to comment.