Skip to content

Revert "Release/fhi-angular-components/3.0.0 (#455)" #36

Revert "Release/fhi-angular-components/3.0.0 (#455)"

Revert "Release/fhi-angular-components/3.0.0 (#455)" #36

name: Automatic publish of @folkehelseinstituttet/angular-components to NPM
on:
push:
branches:
- 'dev'
paths:
- 'projects/fhi-angular-components/package.json'
jobs:
publish:
if: "contains(github.event.head_commit.message, 'Release/fhi-angular-components/')"
name: Build and publish to NPM
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 16
- name: Build fhi-angular-components
run: |
npm install
npm run build-angular-components
- name: Check new npm version and publish
id: publish
uses: JS-DevTools/[email protected]
with:
access: "public"
check-version: true
package: dist/fhi-angular-components/package.json
token: ${{ secrets.NPM_TOKEN }}
- name: Post publish status
if: steps.publish.outputs.type != 'none'
run: |
echo "New Version: ${{ steps.publish.outputs.version }} has replaced old version: ${{ steps.publish.outputs.old-version }}"