From b9fb1e6c428dade8a218b05aa0149b000b5bcecb Mon Sep 17 00:00:00 2001 From: Karthick Shankar Date: Thu, 18 May 2023 15:05:32 -0700 Subject: [PATCH 1/2] add local version and devrelease as inputs --- action.yml | 7 +++++++ entrypoint.sh | 6 ++++++ 2 files changed, 13 insertions(+) diff --git a/action.yml b/action.yml index d3e5d16..d733dc1 100644 --- a/action.yml +++ b/action.yml @@ -30,6 +30,13 @@ inputs: prerelease: description: 'Set as prerelease version' required: false + devrelease: + description: 'Non-negative integer for dev. release' + required: false + local_version: + description: 'Bump only the local version portion' + required: false + default: "false" changelog: description: 'Create changelog when bumping the version' default: "true" diff --git a/entrypoint.sh b/entrypoint.sh index 8a6a7d7..21e6421 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -56,6 +56,12 @@ fi if [[ $INPUT_PRERELEASE ]]; then CZ_CMD+=('--prerelease' "$INPUT_PRERELEASE") fi +if [[ $INPUT_DEVRELEASE ]]; then + CZ_CMD+=('--devrelease' "$INPUT_DEVRELEASE") +fi +if [[ $INPUT_LOCAL_VERSION ]]; then + CZ_CMD+=('--local_version') +fi if [[ $INPUT_COMMIT == 'false' ]]; then CZ_CMD+=('--files-only') fi From 293fe5fd60fc76f891b51a0050eb5d621eab9394 Mon Sep 17 00:00:00 2001 From: Karthick Shankar Date: Thu, 18 May 2023 15:07:08 -0700 Subject: [PATCH 2/2] explicitly check for true in local_version check --- entrypoint.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/entrypoint.sh b/entrypoint.sh index 21e6421..0bc9931 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -59,7 +59,7 @@ fi if [[ $INPUT_DEVRELEASE ]]; then CZ_CMD+=('--devrelease' "$INPUT_DEVRELEASE") fi -if [[ $INPUT_LOCAL_VERSION ]]; then +if [[ $INPUT_LOCAL_VERSION == 'true' ]]; then CZ_CMD+=('--local_version') fi if [[ $INPUT_COMMIT == 'false' ]]; then