trm-core 3.0.0 → 3.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -11,6 +11,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
12
|
exports.acknowledgementSize = void 0;
|
|
13
13
|
const inquirer_1 = require("../../inquirer");
|
|
14
|
+
const logger_1 = require("../../logger");
|
|
14
15
|
exports.acknowledgementSize = {
|
|
15
16
|
name: 'acknowledgement-size',
|
|
16
17
|
filter: (context) => __awaiter(void 0, void 0, void 0, function* () {
|
|
@@ -23,14 +24,20 @@ exports.acknowledgementSize = {
|
|
|
23
24
|
}),
|
|
24
25
|
run: (context) => __awaiter(void 0, void 0, void 0, function* () {
|
|
25
26
|
const size = context.parsedInput.tadir.length;
|
|
26
|
-
const
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
27
|
+
const sMsg = `A total of ${size} objects will be analyzed in order to find dependencies, and it may take a long time.`;
|
|
28
|
+
if (!context.parsedInput.silent) {
|
|
29
|
+
const inq1 = yield inquirer_1.Inquirer.prompt({
|
|
30
|
+
type: 'confirm',
|
|
31
|
+
name: 'continueDependency',
|
|
32
|
+
default: true,
|
|
33
|
+
message: `${sMsg} Continue?`
|
|
34
|
+
});
|
|
35
|
+
if (!inq1.continueDependency) {
|
|
36
|
+
throw new Error(`Process aborted by user.`);
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
else {
|
|
40
|
+
logger_1.Logger.warning(sMsg);
|
|
34
41
|
}
|
|
35
42
|
})
|
|
36
43
|
};
|
|
@@ -24,6 +24,7 @@ export type FindDependencyActionInput = {
|
|
|
24
24
|
systemPackages?: TrmPackage[];
|
|
25
25
|
print?: boolean;
|
|
26
26
|
printSapEntries?: boolean;
|
|
27
|
+
silent?: boolean;
|
|
27
28
|
};
|
|
28
29
|
type WorkflowParsedInput = {
|
|
29
30
|
devclass?: DEVCLASS;
|
|
@@ -31,6 +32,7 @@ type WorkflowParsedInput = {
|
|
|
31
32
|
systemPackages?: TrmPackage[];
|
|
32
33
|
print?: boolean;
|
|
33
34
|
printSapEntries?: boolean;
|
|
35
|
+
silent?: boolean;
|
|
34
36
|
};
|
|
35
37
|
type WorkflowRuntime = {
|
|
36
38
|
devclassIgnore?: DEVCLASS[];
|
|
@@ -29,6 +29,7 @@ exports.init = {
|
|
|
29
29
|
}
|
|
30
30
|
context.parsedInput.tadir = context.rawInput.tadir || [];
|
|
31
31
|
context.parsedInput.systemPackages = context.rawInput.systemPackages || [];
|
|
32
|
+
context.parsedInput.silent = context.rawInput.silent;
|
|
32
33
|
context.output.trmDependencies = [];
|
|
33
34
|
context.output.unknownDependencies = [];
|
|
34
35
|
context.output.sapEntries = [];
|
|
@@ -34,7 +34,8 @@ exports.findDependencies = {
|
|
|
34
34
|
run: (context) => __awaiter(void 0, void 0, void 0, function* () {
|
|
35
35
|
const inputData = {
|
|
36
36
|
devclass: context.parsedInput.devclass,
|
|
37
|
-
tadir: context.runtime.tadirObjects
|
|
37
|
+
tadir: context.runtime.tadirObjects,
|
|
38
|
+
silent: context.parsedInput.silent
|
|
38
39
|
};
|
|
39
40
|
logger_1.Logger.log(`Ready to execute sub-workflow ${SUBWORKFLOW_NAME}, input data: ${JSON.stringify(inputData)}`, true);
|
|
40
41
|
logger_1.Logger.loading(`Searching package dependencies...`);
|