Skip to content

Commit

Permalink
Create Build Test Action
Browse files Browse the repository at this point in the history
  • Loading branch information
Reterics committed Oct 13, 2023
1 parent 8adef07 commit bd3b629
Showing 1 changed file with 40 additions and 0 deletions.
40 changes: 40 additions & 0 deletions .github/workflows/npm-publish-github-packages.yml
@@ -0,0 +1,40 @@
# This workflow will run tests using node and then publish a package to GitHub Packages when a release is created
# For more information see: https://docs.github.com/en/actions/publishing-packages/publishing-nodejs-packages

name: LeJS Package Build

on:
push:
branches: ["main"]
# Runs on any open or reopened pull request
pull_request:
types: [opened, reopened]

# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 16
- run: npm ci
- run: npm test

publish-gpr:
needs: build
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 16
registry-url: https://npm.pkg.github.com/
- run: npm ci
- run: npm run build

0 comments on commit bd3b629

Please sign in to comment.