Skip to content

Commit

Permalink
use queueCommandTasks
Browse files Browse the repository at this point in the history
  • Loading branch information
mshima committed Sep 24, 2024
1 parent 8967fb8 commit b328a56
Show file tree
Hide file tree
Showing 7 changed files with 19 additions and 15 deletions.
4 changes: 4 additions & 0 deletions generators/angular-audit/generator.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@ import { clientApplicationTemplatesBlock } from 'generator-jhipster/generators/c
export default class extends BaseApplicationGenerator {
ngxDiff;

constructor(args, opts, features) {
super(args, opts, { ...features, queueCommandTasks: true });
}

async beforeQueue() {
await this.dependsOnJHipster('bootstrap-application');
}
Expand Down
2 changes: 1 addition & 1 deletion generators/client/generator.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import BaseApplicationGenerator from 'generator-jhipster/generators/base-applica

export default class extends BaseApplicationGenerator {
constructor(args, opts, features) {
super(args, opts, { ...features, sbsBlueprint: true });
super(args, opts, { ...features, queueCommandTasks: true, sbsBlueprint: true });
}

async beforeQueue() {
Expand Down
4 changes: 4 additions & 0 deletions generators/java-audit/generator.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,10 @@ const ADDITIONAL_FIELDS = [
];

export default class extends BaseApplicationGenerator {
constructor(args, opts, features) {
super(args, opts, { ...features, queueCommandTasks: true });
}

async beforeQueue() {
await this.dependsOnJHipster('java');
}
Expand Down
2 changes: 1 addition & 1 deletion generators/languages/generator.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import BaseApplicationGenerator from 'generator-jhipster/generators/base-applica

export default class extends BaseApplicationGenerator {
constructor(args, opts, features) {
super(args, opts, { ...features, sbsBlueprint: true });
super(args, opts, { ...features, queueCommandTasks: true, sbsBlueprint: true });
}

async beforeQueue() {
Expand Down
14 changes: 1 addition & 13 deletions generators/server/generator.js
Original file line number Diff line number Diff line change
@@ -1,30 +1,18 @@
import BaseApplicationGenerator from 'generator-jhipster/generators/base-application';
import command from './command.js';

export default class extends BaseApplicationGenerator {
initialRun;
auditedEntities;

constructor(args, opts, features) {
super(args, opts, { ...features, sbsBlueprint: true });
super(args, opts, { ...features, queueCommandTasks: true, sbsBlueprint: true });
}

get [BaseApplicationGenerator.INITIALIZING]() {
return this.asInitializingTaskGroup({
setInitialRun() {
this.initialRun = this.blueprintConfig.auditFramework === undefined;
},
async initializeOptions() {
this.parseJHipsterCommand(command);
},
});
}

get [BaseApplicationGenerator.PROMPTING]() {
return this.asPromptingTaskGroup({
async promptingTemplateTask() {
await this.prompt(this.prepareQuestions(command.configs));
},
});
}

Expand Down
4 changes: 4 additions & 0 deletions generators/spring-boot-custom-audit/generator.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@ import BaseApplicationGenerator from 'generator-jhipster/generators/base-applica
import { javaMainPackageTemplatesBlock, javaTestPackageTemplatesBlock } from 'generator-jhipster/generators/java/support';

export default class extends BaseApplicationGenerator {
constructor(args, opts, features) {
super(args, opts, { ...features, queueCommandTasks: true });
}

async beforeQueue() {
await this.dependsOnJHipster('jhipster-entity-audit:java-audit');
await this.dependsOnJHipster('spring-boot');
Expand Down
4 changes: 4 additions & 0 deletions generators/spring-boot-javers/generator.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@ import { javaMainPackageTemplatesBlock } from 'generator-jhipster/generators/jav
import { getPomVersionProperties } from 'generator-jhipster/generators/server/support';

export default class extends BaseApplicationGenerator {
constructor(args, opts, features) {
super(args, opts, { ...features, queueCommandTasks: true });
}

async beforeQueue() {
await this.dependsOnJHipster('jhipster-entity-audit:java-audit');
await this.dependsOnJHipster('spring-boot');
Expand Down

0 comments on commit b328a56

Please sign in to comment.