From a0dd287b9e66064b75fb7d837a32ab684f91a5e6 Mon Sep 17 00:00:00 2001 From: tenequm Date: Thu, 9 Nov 2023 20:41:18 +0200 Subject: [PATCH] fix: npm version prerelease when invoked from mangata-node repo --- .github/workflows/pre-release-types.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/pre-release-types.yml b/.github/workflows/pre-release-types.yml index 79ba7dd..843e460 100644 --- a/.github/workflows/pre-release-types.yml +++ b/.github/workflows/pre-release-types.yml @@ -114,8 +114,12 @@ jobs: - name: NPM version bump if: ${{ github.event.inputs.branch != '' }} working-directory: packages/types + env: + INPUTS_BRANCH: ${{ github.event.inputs.branch }} run: | - npm version prerelease --preid=${{ github.event.inputs.branch }} + # Branch name sanitization added to avoid issues with npm version command + # Example `ci/new-branch` -> `ci-new-branch` + npm version prerelease --preid="${INPUTS_BRANCH//\//-}" - name: git add and commit new version if: ${{ github.event.inputs.branch != '' }}