trm-client 6.1.1 → 7.0.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.
- package/LICENSE +20 -20
- package/README.md +65 -65
- package/changelog.txt +179 -165
- package/dist/command/AbstractCommand.d.ts +42 -0
- package/dist/command/AbstractCommand.js +418 -0
- package/dist/command/InquirerType.d.ts +3 -0
- package/dist/command/InquirerType.js +7 -0
- package/dist/{utils/executeCommand.d.ts → command/LoggerType.d.ts} +0 -4
- package/dist/command/LoggerType.js +11 -0
- package/dist/{utils/registerCommand.d.ts → command/RegisterCommandOpts.d.ts} +4 -3
- package/dist/command/implementations/Alias.d.ts +8 -0
- package/dist/command/implementations/Alias.js +172 -0
- package/dist/command/implementations/Compare.d.ts +7 -0
- package/dist/command/implementations/Compare.js +133 -0
- package/dist/command/implementations/Content.d.ts +5 -0
- package/dist/command/implementations/Content.js +195 -0
- package/dist/command/implementations/Deprecate.d.ts +5 -0
- package/dist/command/implementations/Deprecate.js +33 -0
- package/dist/command/implementations/DistTag.d.ts +5 -0
- package/dist/command/implementations/DistTag.js +48 -0
- package/dist/command/implementations/FindDependencies.d.ts +5 -0
- package/dist/command/implementations/FindDependencies.js +42 -0
- package/dist/command/implementations/Info.d.ts +11 -0
- package/dist/command/implementations/Info.js +245 -0
- package/dist/command/implementations/Install.d.ts +13 -0
- package/dist/command/implementations/Install.js +201 -0
- package/dist/command/implementations/List.d.ts +5 -0
- package/dist/command/implementations/List.js +116 -0
- package/dist/command/implementations/Lock.d.ts +5 -0
- package/dist/command/implementations/Lock.js +40 -0
- package/dist/command/implementations/Login.d.ts +5 -0
- package/dist/command/implementations/Login.js +66 -0
- package/dist/command/implementations/Logout.d.ts +5 -0
- package/dist/command/implementations/Logout.js +37 -0
- package/dist/command/implementations/Ping.d.ts +5 -0
- package/dist/{commands/findDependencies.js → command/implementations/Ping.js} +15 -16
- package/dist/command/implementations/Publish.d.ts +6 -0
- package/dist/command/implementations/Publish.js +145 -0
- package/dist/command/implementations/Registry.d.ts +5 -0
- package/dist/command/implementations/Registry.js +88 -0
- package/dist/command/implementations/Settings.d.ts +5 -0
- package/dist/command/implementations/Settings.js +42 -0
- package/dist/command/implementations/Unpublish.d.ts +5 -0
- package/dist/command/implementations/Unpublish.js +34 -0
- package/dist/command/implementations/View.d.ts +9 -0
- package/dist/command/implementations/View.js +237 -0
- package/dist/command/implementations/WhoAmI.d.ts +5 -0
- package/dist/command/implementations/WhoAmI.js +36 -0
- package/dist/command/implementations/index.d.ts +19 -0
- package/dist/command/implementations/index.js +35 -0
- package/dist/command/index.d.ts +4 -0
- package/dist/{commands/commons → command}/index.js +4 -2
- package/dist/{commands/arguments/ConnectArguments.d.ts → command/prompts/connect.d.ts} +2 -0
- package/dist/{commands → command}/prompts/connect.js +3 -3
- package/dist/command/prompts/createAlias.d.ts +1 -0
- package/dist/{commands → command/prompts}/createAlias.js +8 -8
- package/dist/command/prompts/deleteAlias.d.ts +1 -0
- package/dist/{commands → command/prompts}/deleteAlias.js +3 -4
- package/dist/command/prompts/index.d.ts +4 -0
- package/dist/{commands → command}/prompts/index.js +2 -0
- package/dist/index.js +34 -278
- package/dist/registryAlias/RegistryAlias.js +1 -1
- package/dist/systemAlias/SystemAlias.js +4 -4
- package/dist/utils/{Context.d.ts → GlobalContext.d.ts} +3 -3
- package/dist/utils/{Context.js → GlobalContext.js} +6 -6
- package/dist/utils/checkCliUpdate.d.ts +3 -2
- package/dist/utils/checkCliUpdate.js +3 -3
- package/dist/utils/getSapLogonConnections.js +3 -3
- package/dist/utils/index.d.ts +1 -4
- package/dist/utils/index.js +1 -4
- package/package.json +67 -65
- package/dist/commands/addRegistry.d.ts +0 -2
- package/dist/commands/addRegistry.js +0 -66
- package/dist/commands/alias.d.ts +0 -2
- package/dist/commands/alias.js +0 -156
- package/dist/commands/arguments/AddRegistryArguments.d.ts +0 -5
- package/dist/commands/arguments/AliasArguments.d.ts +0 -3
- package/dist/commands/arguments/AliasArguments.js +0 -2
- package/dist/commands/arguments/CheckArguments.d.ts +0 -4
- package/dist/commands/arguments/CheckArguments.js +0 -2
- package/dist/commands/arguments/CompareArguments.d.ts +0 -4
- package/dist/commands/arguments/CompareArguments.js +0 -2
- package/dist/commands/arguments/ConnectArguments.js +0 -2
- package/dist/commands/arguments/ContentArguments.d.ts +0 -6
- package/dist/commands/arguments/ContentArguments.js +0 -2
- package/dist/commands/arguments/CreateAliasArguments.d.ts +0 -3
- package/dist/commands/arguments/CreateAliasArguments.js +0 -2
- package/dist/commands/arguments/DeleteAliasArguments.d.ts +0 -3
- package/dist/commands/arguments/DeleteAliasArguments.js +0 -2
- package/dist/commands/arguments/FindDependenciesArguments.d.ts +0 -5
- package/dist/commands/arguments/FindDependenciesArguments.js +0 -2
- package/dist/commands/arguments/ImportArguments.d.ts +0 -19
- package/dist/commands/arguments/ImportArguments.js +0 -2
- package/dist/commands/arguments/InfoArguments.d.ts +0 -1
- package/dist/commands/arguments/InfoArguments.js +0 -2
- package/dist/commands/arguments/InstallArguments.d.ts +0 -20
- package/dist/commands/arguments/InstallArguments.js +0 -2
- package/dist/commands/arguments/ListArguments.d.ts +0 -3
- package/dist/commands/arguments/ListArguments.js +0 -2
- package/dist/commands/arguments/LockArguments.d.ts +0 -4
- package/dist/commands/arguments/LockArguments.js +0 -2
- package/dist/commands/arguments/LoginArguments.d.ts +0 -4
- package/dist/commands/arguments/LoginArguments.js +0 -2
- package/dist/commands/arguments/LogoutArguments.d.ts +0 -1
- package/dist/commands/arguments/LogoutArguments.js +0 -2
- package/dist/commands/arguments/PackArguments.d.ts +0 -22
- package/dist/commands/arguments/PackArguments.js +0 -2
- package/dist/commands/arguments/PingArguments.d.ts +0 -1
- package/dist/commands/arguments/PingArguments.js +0 -2
- package/dist/commands/arguments/PublishArguments.d.ts +0 -24
- package/dist/commands/arguments/PublishArguments.js +0 -2
- package/dist/commands/arguments/RemoveRegistryArguments.d.ts +0 -4
- package/dist/commands/arguments/RemoveRegistryArguments.js +0 -2
- package/dist/commands/arguments/SettingsArgument.d.ts +0 -3
- package/dist/commands/arguments/SettingsArgument.js +0 -2
- package/dist/commands/arguments/UnpublishArguments.d.ts +0 -4
- package/dist/commands/arguments/UnpublishArguments.js +0 -2
- package/dist/commands/arguments/UpdateArguments.d.ts +0 -2
- package/dist/commands/arguments/UpdateArguments.js +0 -2
- package/dist/commands/arguments/ViewArguments.d.ts +0 -3
- package/dist/commands/arguments/ViewArguments.js +0 -2
- package/dist/commands/arguments/WhoAmIArguments.d.ts +0 -1
- package/dist/commands/arguments/WhoAmIArguments.js +0 -2
- package/dist/commands/arguments/index.d.ts +0 -24
- package/dist/commands/arguments/index.js +0 -40
- package/dist/commands/check.d.ts +0 -2
- package/dist/commands/check.js +0 -87
- package/dist/commands/commons/CommandContext.d.ts +0 -9
- package/dist/commands/commons/CommandContext.js +0 -41
- package/dist/commands/commons/index.d.ts +0 -2
- package/dist/commands/commons/viewRegistryPackage.d.ts +0 -2
- package/dist/commands/commons/viewRegistryPackage.js +0 -48
- package/dist/commands/compare.d.ts +0 -2
- package/dist/commands/compare.js +0 -167
- package/dist/commands/content.d.ts +0 -2
- package/dist/commands/content.js +0 -182
- package/dist/commands/createAlias.d.ts +0 -2
- package/dist/commands/deleteAlias.d.ts +0 -2
- package/dist/commands/findDependencies.d.ts +0 -2
- package/dist/commands/import.d.ts +0 -2
- package/dist/commands/import.js +0 -84
- package/dist/commands/index.d.ts +0 -27
- package/dist/commands/index.js +0 -43
- package/dist/commands/info.d.ts +0 -2
- package/dist/commands/info.js +0 -233
- package/dist/commands/install.d.ts +0 -2
- package/dist/commands/install.js +0 -85
- package/dist/commands/list.d.ts +0 -2
- package/dist/commands/list.js +0 -70
- package/dist/commands/lock.d.ts +0 -2
- package/dist/commands/lock.js +0 -64
- package/dist/commands/login.d.ts +0 -2
- package/dist/commands/login.js +0 -59
- package/dist/commands/logout.d.ts +0 -2
- package/dist/commands/logout.js +0 -27
- package/dist/commands/pack.d.ts +0 -2
- package/dist/commands/pack.js +0 -95
- package/dist/commands/ping.d.ts +0 -2
- package/dist/commands/ping.js +0 -21
- package/dist/commands/prompts/connect.d.ts +0 -3
- package/dist/commands/prompts/index.d.ts +0 -2
- package/dist/commands/publish.d.ts +0 -2
- package/dist/commands/publish.js +0 -128
- package/dist/commands/removeRegistry.d.ts +0 -2
- package/dist/commands/removeRegistry.js +0 -36
- package/dist/commands/selfUpdate.d.ts +0 -1
- package/dist/commands/selfUpdate.js +0 -77
- package/dist/commands/settings.d.ts +0 -2
- package/dist/commands/settings.js +0 -32
- package/dist/commands/unpublish.d.ts +0 -2
- package/dist/commands/unpublish.js +0 -61
- package/dist/commands/update.d.ts +0 -2
- package/dist/commands/update.js +0 -20
- package/dist/commands/view.d.ts +0 -2
- package/dist/commands/view.js +0 -219
- package/dist/commands/whoami.d.ts +0 -2
- package/dist/commands/whoami.js +0 -34
- package/dist/utils/checkTrmDependencies.d.ts +0 -1
- package/dist/utils/checkTrmDependencies.js +0 -43
- package/dist/utils/executeCommand.js +0 -213
- package/dist/utils/registerCommand.js +0 -93
- /package/dist/{commands/arguments/AddRegistryArguments.js → command/RegisterCommandOpts.js} +0 -0
- /package/dist/{commands → command}/prompts/pickRegistry.d.ts +0 -0
- /package/dist/{commands → command}/prompts/pickRegistry.js +0 -0
package/dist/commands/index.d.ts
DELETED
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
export * from "./arguments";
|
|
2
|
-
export * from "./prompts";
|
|
3
|
-
export * from "./publish";
|
|
4
|
-
export * from "./createAlias";
|
|
5
|
-
export * from "./addRegistry";
|
|
6
|
-
export * from "./deleteAlias";
|
|
7
|
-
export * from "./login";
|
|
8
|
-
export * from "./whoami";
|
|
9
|
-
export * from "./logout";
|
|
10
|
-
export * from "./alias";
|
|
11
|
-
export * from "./view";
|
|
12
|
-
export * from "./compare";
|
|
13
|
-
export * from "./install";
|
|
14
|
-
export * from "./list";
|
|
15
|
-
export * from "./ping";
|
|
16
|
-
export * from "./removeRegistry";
|
|
17
|
-
export * from "./unpublish";
|
|
18
|
-
export * from "./info";
|
|
19
|
-
export * from "./check";
|
|
20
|
-
export * from "./findDependencies";
|
|
21
|
-
export * from "./settings";
|
|
22
|
-
export * from "./update";
|
|
23
|
-
export * from "./content";
|
|
24
|
-
export * from "./pack";
|
|
25
|
-
export * from "./import";
|
|
26
|
-
export * from "./selfUpdate";
|
|
27
|
-
export * from "./lock";
|
package/dist/commands/index.js
DELETED
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
-
};
|
|
16
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./arguments"), exports);
|
|
18
|
-
__exportStar(require("./prompts"), exports);
|
|
19
|
-
__exportStar(require("./publish"), exports);
|
|
20
|
-
__exportStar(require("./createAlias"), exports);
|
|
21
|
-
__exportStar(require("./addRegistry"), exports);
|
|
22
|
-
__exportStar(require("./deleteAlias"), exports);
|
|
23
|
-
__exportStar(require("./login"), exports);
|
|
24
|
-
__exportStar(require("./whoami"), exports);
|
|
25
|
-
__exportStar(require("./logout"), exports);
|
|
26
|
-
__exportStar(require("./alias"), exports);
|
|
27
|
-
__exportStar(require("./view"), exports);
|
|
28
|
-
__exportStar(require("./compare"), exports);
|
|
29
|
-
__exportStar(require("./install"), exports);
|
|
30
|
-
__exportStar(require("./list"), exports);
|
|
31
|
-
__exportStar(require("./ping"), exports);
|
|
32
|
-
__exportStar(require("./removeRegistry"), exports);
|
|
33
|
-
__exportStar(require("./unpublish"), exports);
|
|
34
|
-
__exportStar(require("./info"), exports);
|
|
35
|
-
__exportStar(require("./check"), exports);
|
|
36
|
-
__exportStar(require("./findDependencies"), exports);
|
|
37
|
-
__exportStar(require("./settings"), exports);
|
|
38
|
-
__exportStar(require("./update"), exports);
|
|
39
|
-
__exportStar(require("./content"), exports);
|
|
40
|
-
__exportStar(require("./pack"), exports);
|
|
41
|
-
__exportStar(require("./import"), exports);
|
|
42
|
-
__exportStar(require("./selfUpdate"), exports);
|
|
43
|
-
__exportStar(require("./lock"), exports);
|
package/dist/commands/info.d.ts
DELETED
package/dist/commands/info.js
DELETED
|
@@ -1,233 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
-
});
|
|
10
|
-
};
|
|
11
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
12
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
13
|
-
};
|
|
14
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
|
-
exports.info = info;
|
|
16
|
-
const trm_core_1 = require("trm-core");
|
|
17
|
-
const utils_1 = require("../utils");
|
|
18
|
-
const commons_1 = require("./commons");
|
|
19
|
-
const fs_1 = require("fs");
|
|
20
|
-
const path_1 = require("path");
|
|
21
|
-
const get_root_path_1 = require("get-root-path");
|
|
22
|
-
const chalk_1 = __importDefault(require("chalk"));
|
|
23
|
-
const semver_1 = require("semver");
|
|
24
|
-
const trm_commons_1 = require("trm-commons");
|
|
25
|
-
const _getDependencyVersion = (moduleName, rootModule = 'trm-client') => {
|
|
26
|
-
var file;
|
|
27
|
-
try {
|
|
28
|
-
file = (0, fs_1.readFileSync)((0, path_1.join)(get_root_path_1.rootPath, `/node_modules/${rootModule}/node_modules/${moduleName}/package.json`));
|
|
29
|
-
}
|
|
30
|
-
catch (e) {
|
|
31
|
-
file = (0, fs_1.readFileSync)((0, path_1.join)(get_root_path_1.rootPath, `/node_modules/${moduleName}/package.json`));
|
|
32
|
-
}
|
|
33
|
-
if (!file) {
|
|
34
|
-
trm_commons_1.Logger.warning(`Library ${moduleName} (root ${rootModule}) was not found!`, true);
|
|
35
|
-
}
|
|
36
|
-
else {
|
|
37
|
-
return JSON.parse(file.toString()).version;
|
|
38
|
-
}
|
|
39
|
-
};
|
|
40
|
-
const _getNodeRfcVersion = (npmGlobal) => {
|
|
41
|
-
var file;
|
|
42
|
-
try {
|
|
43
|
-
file = (0, fs_1.readFileSync)((0, path_1.join)(npmGlobal, `/node-rfc/package.json`));
|
|
44
|
-
}
|
|
45
|
-
catch (e) {
|
|
46
|
-
}
|
|
47
|
-
if (!file) {
|
|
48
|
-
trm_commons_1.Logger.warning(`Library node-rfc was not found!`, true);
|
|
49
|
-
}
|
|
50
|
-
else {
|
|
51
|
-
return JSON.parse(file.toString()).version;
|
|
52
|
-
}
|
|
53
|
-
};
|
|
54
|
-
const _getNpmLatestForText = (packageName, installedVersion, text) => __awaiter(void 0, void 0, void 0, function* () {
|
|
55
|
-
try {
|
|
56
|
-
const latestVersion = yield (0, utils_1.getNpmPackageLatestVersion)(packageName);
|
|
57
|
-
if ((0, semver_1.gte)(installedVersion, latestVersion)) {
|
|
58
|
-
text += ` ${chalk_1.default.bgGreen('LATEST')}`;
|
|
59
|
-
}
|
|
60
|
-
else {
|
|
61
|
-
text += ` ${chalk_1.default.bold('v' + latestVersion + ' available')}`;
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
catch (e) {
|
|
65
|
-
text += ` ${chalk_1.default.bgGray('Can\'t fetch latest version')}`;
|
|
66
|
-
}
|
|
67
|
-
return text;
|
|
68
|
-
});
|
|
69
|
-
function info(commandArgs) {
|
|
70
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
71
|
-
trm_commons_1.Logger.loading(`Reading data...`);
|
|
72
|
-
const npmGlobal = utils_1.Context.getInstance().getSettings().globalNodeModules;
|
|
73
|
-
const clientLatest = yield (0, utils_1.checkCliUpdate)(false);
|
|
74
|
-
const clientVersion = (0, utils_1.getClientVersion)();
|
|
75
|
-
const clientDependencies = (0, utils_1.getClientNodeDependencies)();
|
|
76
|
-
const trmDependencies = (0, trm_core_1.getCoreTrmDependencies)();
|
|
77
|
-
const trmDependenciesInstances = commons_1.CommandContext.trmDependencies;
|
|
78
|
-
const trmMissingDependencies = commons_1.CommandContext.missingTrmDependencies;
|
|
79
|
-
const nodeRfcVersion = _getNodeRfcVersion(npmGlobal);
|
|
80
|
-
const packages = yield commons_1.CommandContext.getSystemPackages();
|
|
81
|
-
const trmRest = packages.find(o => o.compareName("trm-rest") && o.compareRegistry(trm_core_1.RegistryProvider.getRegistry()));
|
|
82
|
-
var nodeR3transVersion;
|
|
83
|
-
try {
|
|
84
|
-
nodeR3transVersion = _getDependencyVersion("node-r3trans", "trm-core");
|
|
85
|
-
if (!nodeR3transVersion) {
|
|
86
|
-
throw new Error();
|
|
87
|
-
}
|
|
88
|
-
}
|
|
89
|
-
catch (e) {
|
|
90
|
-
nodeR3transVersion = _getDependencyVersion("node-r3trans");
|
|
91
|
-
}
|
|
92
|
-
var clientDependenciesTree = [];
|
|
93
|
-
if (clientDependencies) {
|
|
94
|
-
for (const d of Object.keys(clientDependencies).filter(k => k.startsWith('trm'))) {
|
|
95
|
-
var dText = ``;
|
|
96
|
-
var dInstalledVersion = _getDependencyVersion(d);
|
|
97
|
-
if (dInstalledVersion) {
|
|
98
|
-
dText = ` -> ${dInstalledVersion}`;
|
|
99
|
-
dText = yield _getNpmLatestForText(d, dInstalledVersion, dText);
|
|
100
|
-
}
|
|
101
|
-
clientDependenciesTree.push({
|
|
102
|
-
text: `${d} ${clientDependencies[d]}${dText}`,
|
|
103
|
-
children: []
|
|
104
|
-
});
|
|
105
|
-
}
|
|
106
|
-
}
|
|
107
|
-
var serverDependenciesTree = [];
|
|
108
|
-
if (trmDependencies) {
|
|
109
|
-
for (const d of Object.keys(trmDependencies)) {
|
|
110
|
-
var dText = ``;
|
|
111
|
-
const oTrmPackage = trmDependenciesInstances.find(o => o.compareName(d));
|
|
112
|
-
if (oTrmPackage) {
|
|
113
|
-
var dInstalledVersion;
|
|
114
|
-
try {
|
|
115
|
-
dInstalledVersion = oTrmPackage.manifest.get().version;
|
|
116
|
-
}
|
|
117
|
-
catch (e) {
|
|
118
|
-
dText = ` -> ${e.message}`;
|
|
119
|
-
}
|
|
120
|
-
if (dInstalledVersion) {
|
|
121
|
-
dText = ` -> ${dInstalledVersion}`;
|
|
122
|
-
try {
|
|
123
|
-
const dLatestVersion = (yield oTrmPackage.registry.getPackage(oTrmPackage.packageName, 'latest')).manifest.version;
|
|
124
|
-
if ((0, semver_1.gte)(dInstalledVersion, dLatestVersion)) {
|
|
125
|
-
dText += ` ${chalk_1.default.bgGreen('LATEST')}`;
|
|
126
|
-
}
|
|
127
|
-
else {
|
|
128
|
-
dText += ` ${chalk_1.default.bold('v' + dLatestVersion + ' available')}`;
|
|
129
|
-
}
|
|
130
|
-
}
|
|
131
|
-
catch (e) {
|
|
132
|
-
dText += ` ${chalk_1.default.bgGray('Can\'t fetch latest version')}`;
|
|
133
|
-
}
|
|
134
|
-
}
|
|
135
|
-
}
|
|
136
|
-
else {
|
|
137
|
-
const missingDependency = trmMissingDependencies.find(o => {
|
|
138
|
-
if (typeof (o) === 'string') {
|
|
139
|
-
if (o === d) {
|
|
140
|
-
return o;
|
|
141
|
-
}
|
|
142
|
-
}
|
|
143
|
-
else {
|
|
144
|
-
if (o.compareName(d)) {
|
|
145
|
-
return o;
|
|
146
|
-
}
|
|
147
|
-
}
|
|
148
|
-
});
|
|
149
|
-
if (missingDependency) {
|
|
150
|
-
try {
|
|
151
|
-
dText = ` -> ${chalk_1.default.bgRed(missingDependency.manifest.get().version)}`;
|
|
152
|
-
}
|
|
153
|
-
catch (e) {
|
|
154
|
-
dText = ` -> ${chalk_1.default.bgRed('Not found')}`;
|
|
155
|
-
}
|
|
156
|
-
}
|
|
157
|
-
}
|
|
158
|
-
serverDependenciesTree.push({
|
|
159
|
-
text: `${d} ${trmDependencies[d]}${dText}`,
|
|
160
|
-
children: []
|
|
161
|
-
});
|
|
162
|
-
}
|
|
163
|
-
}
|
|
164
|
-
if (trmRest && trmRest.manifest) {
|
|
165
|
-
serverDependenciesTree.push({
|
|
166
|
-
text: `trm-rest -> ${trmRest.manifest.get().version}`,
|
|
167
|
-
children: []
|
|
168
|
-
});
|
|
169
|
-
}
|
|
170
|
-
var clientChildrenTree = [{
|
|
171
|
-
text: `trm-client ${clientVersion} ${(0, semver_1.gte)(clientLatest.localVersion, clientLatest.latestVersion) ? chalk_1.default.bgGreen('LATEST') : chalk_1.default.bold('v' + clientLatest.latestVersion + ' available')}`,
|
|
172
|
-
children: clientDependenciesTree
|
|
173
|
-
}];
|
|
174
|
-
if (nodeRfcVersion) {
|
|
175
|
-
clientChildrenTree.push({
|
|
176
|
-
text: yield _getNpmLatestForText('node-rfc', nodeRfcVersion, `node-rfc ${nodeRfcVersion}`),
|
|
177
|
-
children: []
|
|
178
|
-
});
|
|
179
|
-
}
|
|
180
|
-
else {
|
|
181
|
-
clientChildrenTree.push({
|
|
182
|
-
text: `node-rfc ${chalk_1.default.bold('not found')}`,
|
|
183
|
-
children: []
|
|
184
|
-
});
|
|
185
|
-
}
|
|
186
|
-
if (nodeR3transVersion) {
|
|
187
|
-
clientChildrenTree.push({
|
|
188
|
-
text: yield _getNpmLatestForText('node-r3trans', nodeR3transVersion, `node-r3trans ${nodeR3transVersion}`),
|
|
189
|
-
children: []
|
|
190
|
-
});
|
|
191
|
-
}
|
|
192
|
-
else {
|
|
193
|
-
clientChildrenTree.push({
|
|
194
|
-
text: `node-r3trans ${chalk_1.default.bold('not found')}`,
|
|
195
|
-
children: []
|
|
196
|
-
});
|
|
197
|
-
}
|
|
198
|
-
const clientTree = {
|
|
199
|
-
text: chalk_1.default.bold(`Client`),
|
|
200
|
-
children: clientChildrenTree
|
|
201
|
-
};
|
|
202
|
-
const serverTree = {
|
|
203
|
-
text: chalk_1.default.bold(`Server (${trm_core_1.SystemConnector.getDest()})`),
|
|
204
|
-
children: serverDependenciesTree
|
|
205
|
-
};
|
|
206
|
-
const pluginsTree = {
|
|
207
|
-
text: chalk_1.default.bold(`Plugins`),
|
|
208
|
-
children: []
|
|
209
|
-
};
|
|
210
|
-
for (const plugin of utils_1.Context.getInstance().getPlugins()) {
|
|
211
|
-
try {
|
|
212
|
-
const installedVersion = JSON.parse((0, fs_1.readFileSync)((0, path_1.join)(plugin.location, 'package.json')).toString()).version;
|
|
213
|
-
pluginsTree.children.push({
|
|
214
|
-
text: yield _getNpmLatestForText(plugin.name, installedVersion, `${plugin.name} ${installedVersion}`),
|
|
215
|
-
children: []
|
|
216
|
-
});
|
|
217
|
-
}
|
|
218
|
-
catch (_a) {
|
|
219
|
-
pluginsTree.children.push({
|
|
220
|
-
text: plugin.name,
|
|
221
|
-
children: []
|
|
222
|
-
});
|
|
223
|
-
}
|
|
224
|
-
}
|
|
225
|
-
trm_commons_1.Logger.tree(clientTree);
|
|
226
|
-
if (!(trm_core_1.SystemConnector.systemConnector instanceof utils_1.DummyConnector)) {
|
|
227
|
-
trm_commons_1.Logger.tree(serverTree);
|
|
228
|
-
}
|
|
229
|
-
if (pluginsTree.children.length > 0) {
|
|
230
|
-
trm_commons_1.Logger.tree(pluginsTree);
|
|
231
|
-
}
|
|
232
|
-
});
|
|
233
|
-
}
|
package/dist/commands/install.js
DELETED
|
@@ -1,85 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
-
});
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.install = install;
|
|
13
|
-
const trm_core_1 = require("trm-core");
|
|
14
|
-
const utils_1 = require("../utils");
|
|
15
|
-
const commons_1 = require("./commons");
|
|
16
|
-
const trm_commons_1 = require("trm-commons");
|
|
17
|
-
const _parsePackageReplacementsArgument = (arg) => {
|
|
18
|
-
if (arg) {
|
|
19
|
-
try {
|
|
20
|
-
return JSON.parse(arg);
|
|
21
|
-
}
|
|
22
|
-
catch (e) { }
|
|
23
|
-
}
|
|
24
|
-
};
|
|
25
|
-
const _parseImportTimeoutArg = (arg) => {
|
|
26
|
-
if (arg) {
|
|
27
|
-
try {
|
|
28
|
-
return parseInt(arg);
|
|
29
|
-
}
|
|
30
|
-
catch (e) { }
|
|
31
|
-
}
|
|
32
|
-
};
|
|
33
|
-
function install(commandArgs) {
|
|
34
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
35
|
-
const packages = yield commons_1.CommandContext.getSystemPackages();
|
|
36
|
-
const result = yield (0, trm_core_1.install)({
|
|
37
|
-
contextData: {
|
|
38
|
-
r3transOptions: {
|
|
39
|
-
tempDirPath: (0, utils_1.getTempFolder)(),
|
|
40
|
-
r3transDirPath: commandArgs.r3transPath,
|
|
41
|
-
useDocker: utils_1.Context.getInstance().getSettings().r3transDocker,
|
|
42
|
-
dockerOptions: {
|
|
43
|
-
name: utils_1.Context.getInstance().getSettings().r3transDockerName
|
|
44
|
-
}
|
|
45
|
-
},
|
|
46
|
-
noInquirer: commandArgs.noPrompts,
|
|
47
|
-
systemPackages: packages,
|
|
48
|
-
noR3transInfo: false
|
|
49
|
-
},
|
|
50
|
-
packageData: {
|
|
51
|
-
name: commandArgs.package,
|
|
52
|
-
version: commandArgs.version,
|
|
53
|
-
overwrite: commandArgs.overwrite,
|
|
54
|
-
registry: commons_1.CommandContext.getRegistry()
|
|
55
|
-
},
|
|
56
|
-
installData: {
|
|
57
|
-
checks: {
|
|
58
|
-
noDependencies: commandArgs.noDependencies,
|
|
59
|
-
noObjectTypes: commandArgs.noObjectTypes,
|
|
60
|
-
noSapEntries: commandArgs.noSapEntries,
|
|
61
|
-
noExistingObjects: commandArgs.overwrite
|
|
62
|
-
},
|
|
63
|
-
import: {
|
|
64
|
-
noLang: commandArgs.noLanguageTransport,
|
|
65
|
-
noCust: commandArgs.noCustomizingTransport,
|
|
66
|
-
timeout: _parseImportTimeoutArg(commandArgs.importTimeout)
|
|
67
|
-
},
|
|
68
|
-
installDevclass: {
|
|
69
|
-
keepOriginal: commandArgs.keepOriginalPackages,
|
|
70
|
-
transportLayer: commandArgs.transportLayer,
|
|
71
|
-
replacements: _parsePackageReplacementsArgument(commandArgs.packageReplacements)
|
|
72
|
-
},
|
|
73
|
-
installTransport: {
|
|
74
|
-
create: commandArgs.createInstallTransport,
|
|
75
|
-
targetSystem: commandArgs.installTransportTargetSys
|
|
76
|
-
}
|
|
77
|
-
}
|
|
78
|
-
});
|
|
79
|
-
var sOutput = `${result.manifest.name} v${result.manifest.version} installed`;
|
|
80
|
-
if (result.installTransport) {
|
|
81
|
-
sOutput += `, use ${result.installTransport.trkorr} transport in landscape`;
|
|
82
|
-
}
|
|
83
|
-
trm_commons_1.Logger.success(sOutput);
|
|
84
|
-
});
|
|
85
|
-
}
|
package/dist/commands/list.d.ts
DELETED
package/dist/commands/list.js
DELETED
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
-
});
|
|
10
|
-
};
|
|
11
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
12
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
13
|
-
};
|
|
14
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
|
-
exports.list = list;
|
|
16
|
-
const trm_core_1 = require("trm-core");
|
|
17
|
-
const commons_1 = require("./commons");
|
|
18
|
-
const chalk_1 = __importDefault(require("chalk"));
|
|
19
|
-
const trm_commons_1 = require("trm-commons");
|
|
20
|
-
function list(commandArgs) {
|
|
21
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
22
|
-
trm_commons_1.Logger.loading(`Reading packages...`);
|
|
23
|
-
const dest = trm_core_1.SystemConnector.getDest();
|
|
24
|
-
var aPackages = yield commons_1.CommandContext.getSystemPackages();
|
|
25
|
-
var iLocals = aPackages.filter(o => o.registry.getRegistryType() === trm_core_1.RegistryType.LOCAL).length;
|
|
26
|
-
if (!commandArgs.locals) {
|
|
27
|
-
aPackages = aPackages.filter(o => o.registry.getRegistryType() !== trm_core_1.RegistryType.LOCAL);
|
|
28
|
-
}
|
|
29
|
-
if (aPackages.length > 0) {
|
|
30
|
-
const tableHead = [`Name`, `Version`, `Registry`, `Devclass`, `TRM transport`, `Landscape transport`];
|
|
31
|
-
var tableData = [];
|
|
32
|
-
for (const oPackage of aPackages) {
|
|
33
|
-
try {
|
|
34
|
-
const packageName = oPackage.packageName || '';
|
|
35
|
-
const version = oPackage.manifest.get().version || '';
|
|
36
|
-
const registry = oPackage.registry.getRegistryType() === trm_core_1.RegistryType.LOCAL ? chalk_1.default.bold(oPackage.registry.name) : oPackage.registry.name;
|
|
37
|
-
const devclass = oPackage.getDevclass() || '';
|
|
38
|
-
const linkedTransport = oPackage.manifest.getLinkedTransport();
|
|
39
|
-
const landscapeTransport = yield oPackage.getWbTransport();
|
|
40
|
-
var importTransport = '';
|
|
41
|
-
if (linkedTransport && (yield linkedTransport.isImported())) {
|
|
42
|
-
importTransport = linkedTransport.trkorr;
|
|
43
|
-
}
|
|
44
|
-
tableData.push([
|
|
45
|
-
packageName,
|
|
46
|
-
version,
|
|
47
|
-
registry,
|
|
48
|
-
devclass,
|
|
49
|
-
importTransport,
|
|
50
|
-
landscapeTransport ? landscapeTransport.trkorr : ''
|
|
51
|
-
]);
|
|
52
|
-
}
|
|
53
|
-
catch (e) {
|
|
54
|
-
trm_commons_1.Logger.error(e, true);
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
if (tableData.length < aPackages.length) {
|
|
58
|
-
trm_commons_1.Logger.warning(`${aPackages.length - tableData.length} packages couldn't be printed (check logs).`);
|
|
59
|
-
}
|
|
60
|
-
trm_commons_1.Logger.info(`${dest} has ${aPackages.length} packages.`);
|
|
61
|
-
trm_commons_1.Logger.table(tableHead, tableData);
|
|
62
|
-
if (iLocals > 0 && !commandArgs.locals) {
|
|
63
|
-
trm_commons_1.Logger.warning(`There ${iLocals === 1 ? 'is' : 'are'} ${iLocals} local package${iLocals === 1 ? '' : 's'}. Run with option -l (--locals) to list ${iLocals === 1 ? 'it' : 'them'}.`);
|
|
64
|
-
}
|
|
65
|
-
}
|
|
66
|
-
else {
|
|
67
|
-
trm_commons_1.Logger.info(`${dest} has 0 packages.`);
|
|
68
|
-
}
|
|
69
|
-
});
|
|
70
|
-
}
|
package/dist/commands/lock.d.ts
DELETED
package/dist/commands/lock.js
DELETED
|
@@ -1,64 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
-
});
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.lock = lock;
|
|
13
|
-
const trm_core_1 = require("trm-core");
|
|
14
|
-
const commons_1 = require("./commons");
|
|
15
|
-
const trm_commons_1 = require("trm-commons");
|
|
16
|
-
const fs_1 = require("fs");
|
|
17
|
-
function resolveRegistry(registry) {
|
|
18
|
-
if (!registry || registry.trim().toLowerCase() === trm_core_1.PUBLIC_RESERVED_KEYWORD) {
|
|
19
|
-
return 'https://trmregistry.com/registry/';
|
|
20
|
-
}
|
|
21
|
-
else {
|
|
22
|
-
return registry;
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
function lock(commandArgs) {
|
|
26
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
27
|
-
var lock = {
|
|
28
|
-
lockfileVersion: 1,
|
|
29
|
-
packages: []
|
|
30
|
-
};
|
|
31
|
-
const packages = yield commons_1.CommandContext.getSystemPackages();
|
|
32
|
-
const root = packages.find(o => o.compareName(commandArgs.package) && o.compareRegistry(commons_1.CommandContext.getRegistry()));
|
|
33
|
-
if (!root) {
|
|
34
|
-
throw new Error(`Package "${commandArgs.package}" not found`);
|
|
35
|
-
}
|
|
36
|
-
const rootManifest = root.manifest.get();
|
|
37
|
-
var dependencies = rootManifest.dependencies || [];
|
|
38
|
-
lock.name = rootManifest.name;
|
|
39
|
-
lock.version = rootManifest.version;
|
|
40
|
-
for (const dep of dependencies) {
|
|
41
|
-
const registryResolved = resolveRegistry(dep.registry);
|
|
42
|
-
if (!lock.packages.find(o => o.name === dep.name && o.registry === registryResolved)) {
|
|
43
|
-
const depRegistry = trm_core_1.RegistryProvider.getRegistry(dep.registry);
|
|
44
|
-
const depPackage = packages.find(o => o.compareName(dep.name) && o.compareRegistry(depRegistry));
|
|
45
|
-
if (depPackage) {
|
|
46
|
-
const depManifest = depPackage.manifest.get();
|
|
47
|
-
const depIntegrity = yield trm_core_1.SystemConnector.getPackageIntegrity(depPackage);
|
|
48
|
-
lock.packages.push({
|
|
49
|
-
name: dep.name,
|
|
50
|
-
version: depManifest.version,
|
|
51
|
-
registry: registryResolved,
|
|
52
|
-
integrity: depIntegrity
|
|
53
|
-
});
|
|
54
|
-
dependencies = dependencies.concat(depManifest.dependencies || []);
|
|
55
|
-
}
|
|
56
|
-
else {
|
|
57
|
-
trm_commons_1.Logger.warning(`Dependency "${dep.name}", registry "${registryResolved}" not found in system ${trm_core_1.SystemConnector.getDest()}`);
|
|
58
|
-
}
|
|
59
|
-
}
|
|
60
|
-
}
|
|
61
|
-
(0, fs_1.writeFileSync)(commandArgs.outputPath, JSON.stringify(lock, null, 2));
|
|
62
|
-
trm_commons_1.Logger.info(`Generated lock file "${commandArgs.outputPath}"`);
|
|
63
|
-
});
|
|
64
|
-
}
|
package/dist/commands/login.d.ts
DELETED
package/dist/commands/login.js
DELETED
|
@@ -1,59 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
-
});
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.login = login;
|
|
13
|
-
const registryAlias_1 = require("../registryAlias");
|
|
14
|
-
const whoami_1 = require("./whoami");
|
|
15
|
-
const commons_1 = require("./commons");
|
|
16
|
-
const trm_commons_1 = require("trm-commons");
|
|
17
|
-
function login(commandArgs) {
|
|
18
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
19
|
-
var continueLogin = false;
|
|
20
|
-
if (!commandArgs.force) {
|
|
21
|
-
try {
|
|
22
|
-
const whoami = yield commons_1.CommandContext.getRegistry().whoAmI();
|
|
23
|
-
const inq1 = yield trm_commons_1.Inquirer.prompt({
|
|
24
|
-
type: "confirm",
|
|
25
|
-
name: "continue",
|
|
26
|
-
message: `Already logged in as "${whoami.user}". Do you want to logout?`,
|
|
27
|
-
default: false
|
|
28
|
-
});
|
|
29
|
-
continueLogin = inq1.continue;
|
|
30
|
-
}
|
|
31
|
-
catch (e) {
|
|
32
|
-
continueLogin = true;
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
else {
|
|
36
|
-
continueLogin = true;
|
|
37
|
-
}
|
|
38
|
-
if (continueLogin) {
|
|
39
|
-
const auth = commandArgs.authentication;
|
|
40
|
-
var oAuth;
|
|
41
|
-
if (auth) {
|
|
42
|
-
try {
|
|
43
|
-
oAuth = JSON.parse(auth);
|
|
44
|
-
}
|
|
45
|
-
catch (e) {
|
|
46
|
-
throw new Error(`Invalid authentication JSON object.`);
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
else {
|
|
50
|
-
oAuth = undefined;
|
|
51
|
-
}
|
|
52
|
-
yield commons_1.CommandContext.getRegistry().authenticate(oAuth);
|
|
53
|
-
oAuth = commons_1.CommandContext.getRegistry().getAuthData();
|
|
54
|
-
trm_commons_1.Logger.success('Logged in.');
|
|
55
|
-
registryAlias_1.RegistryAlias.update(commons_1.CommandContext.getRegistry().name, oAuth);
|
|
56
|
-
yield (0, whoami_1.whoami)({});
|
|
57
|
-
}
|
|
58
|
-
});
|
|
59
|
-
}
|
package/dist/commands/logout.js
DELETED
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
-
});
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.logout = logout;
|
|
13
|
-
const trm_commons_1 = require("trm-commons");
|
|
14
|
-
const registryAlias_1 = require("../registryAlias");
|
|
15
|
-
const commons_1 = require("./commons");
|
|
16
|
-
function logout(commandArgs) {
|
|
17
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
18
|
-
try {
|
|
19
|
-
yield commons_1.CommandContext.getRegistry().whoAmI();
|
|
20
|
-
registryAlias_1.RegistryAlias.update(commons_1.CommandContext.getRegistry().name, null);
|
|
21
|
-
trm_commons_1.Logger.info(`Logged out.`);
|
|
22
|
-
}
|
|
23
|
-
catch (e) {
|
|
24
|
-
trm_commons_1.Logger.info(`Not logged in. Did you mean to use command "login"?`);
|
|
25
|
-
}
|
|
26
|
-
});
|
|
27
|
-
}
|
package/dist/commands/pack.d.ts
DELETED