Skip to content

2.0.1

2.0.1 #8

Workflow file for this run

name: Build and Release NPM to GPR (GitHub Package Registry)
on:
release:
types: [published]
workflow_dispatch:
jobs:
build-deploy:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
- name: Setup node
uses: actions/setup-node@v3
with:
node-version: 18
registry-url: https://npm.pkg.github.com/
scope: '@mitre'
- name: Build the NPM Package
run: |
npm install
npm run build
- name: Pack all items that are published
run: npm pack
# Setup .npmrc file to publish to GitHub Package Registry
- uses: actions/setup-node@v1
with:
registry-url: 'https://npm.pkg.github.com'
scope: '@mitre'
# Publish inspec-objects to GitHub Package Registry
- name: Publish inspec-objects to GPR
run: npm publish mitre-inspec-objects-*.tgz
env:
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}