Skip to content

Commit

Permalink
NPM CI
Browse files Browse the repository at this point in the history
  • Loading branch information
kishannareshpal committed Feb 6, 2024
1 parent f2f4365 commit df5cf77
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 9 deletions.
10 changes: 8 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,17 @@ on: [push]

jobs:
build:
name: "Build (and lint) the package"
runs-on: ubuntu-latest
timeout-minutes: 2
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20.x
- run: npm ci
- run: npm run build

- name: Install NPM dependencies
run: npm ci

- name: Build (and lint) the package
run: npm run build
19 changes: 12 additions & 7 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
name: Publish
on:
release:
types: [published]
workflow_run:
branches: [main]
types: [completed]
types:
created

jobs:
publish:
name: "Publish NPM package to GitHub Packages"
runs-on: ubuntu-latest
timeout-minutes: 2
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
Expand All @@ -23,8 +22,14 @@ jobs:
node-version: 20.x
registry-url: 'https://npm.pkg.github.com'
scope: '@the-curve-consulting'
- run: npm ci
- run: npm build
- run: npm publish

- name: Install NPM dependencies
run: npm ci

- name: Build (and lint) the package
run: npm run build

- name: Publish the package
run: npm publish
env:
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit df5cf77

Please sign in to comment.