Skip to content

Merge pull request #4 from natahouse/develop #4

Merge pull request #4 from natahouse/develop

Merge pull request #4 from natahouse/develop #4

Workflow file for this run

name: Publish Configurations on Release
on:
push:
branches:
- main
permissions:
contents: write
jobs:
publish:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: 18.x
registry-url: "https://registry.npmjs.org"
- name: Install dependencies
run: npm install
- uses: actions/cache@v3
name: Setup npm cache
with:
path: ~/.npm
key: ${{ runner.os }}-node-modules-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-modules-
- name: Create Release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
release_name: Release git describe HEAD --abbrev=0
tag_name: git describe HEAD --abbrev=0
body_path: CHANGELOG.md
draft: false
prerelease: false
- name: Login to npm
run: echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}" > ~/.npmrc
- name: Publish Configuration to NPM
run: npm publish --verbose --access public
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}