From 79d4afbba1b4eff8b9a98e3d2e58c4dbaf094e2b Mon Sep 17 00:00:00 2001 From: Carlos Alexandro Becker Date: Fri, 14 Jan 2022 13:50:06 -0300 Subject: [PATCH] fix: should not force snapshot when nightly is set (#321) * fix: should not force snapshot when nightly is set Signed-off-by: Carlos A Becker * fix: build Signed-off-by: Carlos A Becker --- dist/index.js | 4 ++-- src/main.ts | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/dist/index.js b/dist/index.js index 1a8a356..5280f82 100644 --- a/dist/index.js +++ b/dist/index.js @@ -346,8 +346,8 @@ function run() { let snapshot = ''; if (args.split(' ').indexOf('release') > -1) { if (isTagDirty) { - core.info(`No tag found for commit ${commit}. Snapshot forced`); - if (!args.includes('--snapshot')) { + if (!args.includes('--snapshot') && !args.includes('--nightly')) { + core.info(`No tag found for commit ${commit}. Snapshot forced`); snapshot = ' --snapshot'; } } diff --git a/src/main.ts b/src/main.ts index 02923b1..e3a4f4b 100644 --- a/src/main.ts +++ b/src/main.ts @@ -36,8 +36,8 @@ async function run(): Promise { let snapshot = ''; if (args.split(' ').indexOf('release') > -1) { if (isTagDirty) { - core.info(`No tag found for commit ${commit}. Snapshot forced`); - if (!args.includes('--snapshot')) { + if (!args.includes('--snapshot') && !args.includes('--nightly')) { + core.info(`No tag found for commit ${commit}. Snapshot forced`); snapshot = ' --snapshot'; } } else {