Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build and Release NPM to GPR (GitHub Package Registry) | |
on: | |
release: | |
types: [published] | |
workflow_dispatch: | |
jobs: | |
build-deploy: | |
runs-on: ubuntu-24.04 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup node | |
uses: actions/setup-node@v4 | |
with: | |
node-version: 22 | |
registry-url: 'https://npm.pkg.github.com' | |
scope: '@mitre' | |
- name: Install project dependencies | |
run: npm ci | |
- name: Remove testing resources | |
run: rm -rf test | |
- name: Build | |
run: npm run build | |
- name: Pack all items that are published as packages | |
run: npm pack | |
- name: Publish inspec-objects to GPR | |
run: npm publish mitre-inspec-objects-*.tgz | |
env: | |
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }} |