Skip to content

Commit

Permalink
ci: add github actions for check build and publish
Browse files Browse the repository at this point in the history
  • Loading branch information
kentacho committed Jan 18, 2024
1 parent 75938f5 commit 02e0271
Show file tree
Hide file tree
Showing 2 changed files with 43 additions and 0 deletions.
18 changes: 18 additions & 0 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: Check Build
on: push

jobs:
check-build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- uses: actions/setup-node@v4
with:
node-version: '16'

- run: npm ci

- run: npm run build ngx-golden-layout

- run: npm run build ngx-golden-layout-testbed
25 changes: 25 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Publish to NPM
on:
push:
tags:
- v*

jobs:
publish:
environment: production
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- uses: actions/setup-node@v4
with:
node-version: '16'
registry-url: 'https://registry.npmjs.org/'

- run: npm ci

- run: npm run build ngx-golden-layout

- run: npm publish ./dist/ngx-golden-layout
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

0 comments on commit 02e0271

Please sign in to comment.