Skip to content

Commit

Permalink
blueprints: accept string blueprint option as backward compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
mshima committed Sep 23, 2024
1 parent 00a3efe commit 211b129
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion generators/base/generator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -540,8 +540,11 @@ export default class JHipsterBaseBlueprintGenerator<TaskTypes extends BaseTaskTy
private async _configureBlueprints() {
let argvBlueprints = this.options.blueprints || '';
// check for old single blueprint declaration
const { blueprint } = this.options;
let { blueprint } = this.options;
if (blueprint) {
if (typeof blueprint === 'string') {
blueprint = [blueprint];
}
this.log.warn('--blueprint option is deprecated. Please use --blueprints instead');
argvBlueprints = union(blueprint, argvBlueprints.split(',')).join(',');
}
Expand Down

0 comments on commit 211b129

Please sign in to comment.