Skip to content

Commit

Permalink
build: fix release automation
Browse files Browse the repository at this point in the history
Adds a GitHub workflow yaml file that executes the
publish script.
This workflow only gets triggered when a git tag has been
created that starts with the letter v (as in version).

Fixes hyperledger-cacti#1951
Fixes hyperledger-cacti#2054
Fixes hyperledger-cacti#2175

Signed-off-by: Peter Somogyvari <[email protected]>
  • Loading branch information
petermetz committed Oct 20, 2022
1 parent cc8deb8 commit dfb90a4
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions .github/workflows/all-nodejs-packages-publish.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: all-nodejs-packages-publish

on:
push:

# Publish `v1.2.3` tags as releases.
tags:
- v*

jobs:

build-and-publish-packages:
runs-on: ubuntu-20.04
steps:
- uses: actions/[email protected]
- run: git fetch --unshallow --prune
- uses: actions/[email protected]
with:
always-auth: true
node-version: '16.14.2'
registry-url: 'https://registry.npmjs.org'
- name: lerna-publish
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
run: |
git config --global user.email "${GITHUB_ACTOR}"
git config --global user.name "${GITHUB_ACTOR}"
yarn run configure
yarn run build
yarn lerna publish from-git --yes --loglevel=debug

0 comments on commit dfb90a4

Please sign in to comment.