Skip to content
Snippets Groups Projects
Commit 69f77c01 authored by Adam Moss's avatar Adam Moss Committed by Rhys Arkins
Browse files

fix(semanticCommitScope): compile with handlebars


Compile the semanticCommitScope with handlebars to ensure any
substitutions such as {{depName}} are correctly parsed and replaced.

Closes #1504

Signed-off-by: default avatarAdam Moss <adam.moss@bcs.org.uk>
parent 2793c4c8
No related branches found
No related tags found
No related merge requests found
......@@ -16,7 +16,9 @@ async function commitFilesToBranch(config) {
splitMessage[0] = splitMessage[0].toLowerCase();
let semanticPrefix = config.semanticCommitType;
if (config.semanticCommitScope) {
semanticPrefix += `(${config.semanticCommitScope})`;
semanticPrefix += `(${handlebars.compile(config.semanticCommitScope)(
config
)})`;
}
commitMessage = `${semanticPrefix}: ${splitMessage.join('\n')}`;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment