Skip to content

Commit

Permalink
feat: add --lerna-package flag used to extract tags in case of lerna …
Browse files Browse the repository at this point in the history
…repo (#503)

Co-authored-by: Benjamin E. Coe <[email protected]>
  • Loading branch information
micaelmbagira and bcoe authored May 4, 2021
1 parent 3d341c2 commit f579ff0
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
4 changes: 4 additions & 0 deletions command.js
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,10 @@ const yargs = require('yargs')
default: defaults.preset,
describe: 'Commit message guideline preset'
})
.option('lerna-package', {
type: 'string',
describe: 'Name of the package from which the tags will be extracted'
})
.check((argv) => {
if (typeof argv.scripts !== 'object' || Array.isArray(argv.scripts)) {
throw Error('scripts must be an object')
Expand Down
3 changes: 2 additions & 1 deletion lib/lifecycles/bump.js
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,8 @@ function bumpVersion (releaseAs, currentVersion, args) {
debug: args.verbose && console.info.bind(console, 'conventional-recommended-bump'),
preset: presetOptions,
path: args.path,
tagPrefix: args.tagPrefix
tagPrefix: args.tagPrefix,
lernaPackage: args.lernaPackage
}, function (err, release) {
if (err) return reject(err)
else return resolve(release)
Expand Down

0 comments on commit f579ff0

Please sign in to comment.