Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
const packageName = require('../package').name
const suffix = '-commit-message'
const name = packageName.split(suffix)[0]
module.exports = {
name: name,
// TODO use functions from validate-commit-message
// and from https://github.com/commitizen/cz-conventional-changelog
parse: require('./valid-message').parse,
validate: require('./valid-message').validate,
prompter: require('cz-conventional-changelog').prompter
}
const commitMessage = await new Promise((resolve, reject) => {
czConventionalChangelog.prompter(inquirer, (commitMessage) => {
resolve(commitMessage);
});
});