5
0
Fork 0
mirror of https://github.com/cycjimmy/semantic-release-action.git synced 2025-11-07 10:46:56 +00:00

feat: support for option tagFormat

This commit is contained in:
Joel Humberto Gomez Paredes 2023-03-03 04:25:24 -06:00
parent 9a76e06dfe
commit ed38eb0e99
3 changed files with 20 additions and 1 deletions

View file

@ -77,3 +77,19 @@ exports.handleExtends = () => {
return {};
}
};
/**
* Handle TagFormat Option
* @returns {{}|{tagFormat: String}}
*/
exports.handleTagFormat = () => {
const tagFormat = core.getInput(inputs.tagFormat);
if (tagFormat) {
return {
tagFormat
};
} else {
return {};
}
};

View file

@ -3,6 +3,7 @@ const {
handleBranchesOption,
handleDryRunOption,
handleExtends,
handleTagFormat,
} = require('./handleOptions');
const setUpJob = require('./setUpJob.task');
const installSpecifyingVersionSemantic = require('./installSpecifyingVersionSemantic.task');
@ -29,6 +30,7 @@ const release = async () => {
...handleBranchesOption(),
...handleDryRunOption(),
...handleExtends(),
...handleTagFormat()
});
await cleanupNpmrc();

View file

@ -5,5 +5,6 @@
"extra_plugins": "extra_plugins",
"dry_run": "dry_run",
"extends": "extends",
"working_directory": "working_directory"
"working_directory": "working_directory",
"tagFormat": "tagFormat"
}