fmt
This commit is contained in:
parent
279b636703
commit
933159043f
7
index.js
7
index.js
|
@ -20,7 +20,7 @@ const pkg = getPackageJson();
|
||||||
console.log("Couldn't find any commits in this event, incrementing patch version...");
|
console.log("Couldn't find any commits in this event, incrementing patch version...");
|
||||||
}
|
}
|
||||||
|
|
||||||
const allowedTypes = ['major', 'minor', 'patch', 'prerelease']
|
const allowedTypes = ['major', 'minor', 'patch', 'prerelease'];
|
||||||
if (process.env['INPUT_VERSION-TYPE'] && !allowedTypes.includes(process.env['INPUT_VERSION-TYPE'])) {
|
if (process.env['INPUT_VERSION-TYPE'] && !allowedTypes.includes(process.env['INPUT_VERSION-TYPE'])) {
|
||||||
exitFailure('Invalid version type');
|
exitFailure('Invalid version type');
|
||||||
return;
|
return;
|
||||||
|
@ -103,7 +103,7 @@ const pkg = getPackageJson();
|
||||||
}),
|
}),
|
||||||
)
|
)
|
||||||
) {
|
) {
|
||||||
if (foundWord !== ''){
|
if (foundWord !== '') {
|
||||||
preid = foundWord.split('-')[1];
|
preid = foundWord.split('-')[1];
|
||||||
}
|
}
|
||||||
version = 'prerelease';
|
version = 'prerelease';
|
||||||
|
@ -119,8 +119,7 @@ const pkg = getPackageJson();
|
||||||
if (
|
if (
|
||||||
version === 'prerelease' &&
|
version === 'prerelease' &&
|
||||||
preReleaseWords &&
|
preReleaseWords &&
|
||||||
!messages.some((message) => preReleaseWords.some((word) => message.includes(word)) &&
|
!messages.some((message) => preReleaseWords.some((word) => message.includes(word)) && !versionType)
|
||||||
!versionType)
|
|
||||||
) {
|
) {
|
||||||
version = null;
|
version = null;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue