libmodulor 0.25.0 → 0.27.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/CHANGELOG.md +23 -0
- package/README.md +32 -151
- package/dist/esm/app/workers/AppUCsLoader.d.ts +2 -3
- package/dist/esm/apps/Helper/src/i18n.d.ts +39 -2
- package/dist/esm/apps/Helper/src/i18n.js +15 -1
- package/dist/esm/apps/Helper/src/lib/SrcFilesGenerator.d.ts +13 -0
- package/dist/esm/apps/Helper/src/lib/SrcFilesGenerator.js +37 -0
- package/dist/esm/apps/Helper/src/lib/consts.d.ts +2 -0
- package/dist/esm/apps/Helper/src/lib/consts.js +2 -0
- package/dist/esm/apps/Helper/src/lib/funcs.d.ts +4 -0
- package/dist/esm/apps/Helper/src/lib/funcs.js +9 -0
- package/dist/esm/apps/Helper/src/lib/io.d.ts +10 -0
- package/dist/esm/apps/Helper/src/lib/io.js +22 -0
- package/dist/esm/apps/Helper/src/lib/layers/app.d.ts +3 -0
- package/dist/esm/apps/Helper/src/lib/layers/app.js +30 -0
- package/dist/esm/apps/Helper/src/lib/layers/product.d.ts +3 -0
- package/dist/esm/apps/Helper/src/lib/layers/product.js +27 -0
- package/dist/esm/apps/Helper/src/lib/layers/project.d.ts +4 -0
- package/dist/esm/apps/Helper/src/lib/layers/project.js +163 -0
- package/dist/esm/apps/Helper/src/lib/layers/target.d.ts +3 -0
- package/dist/esm/apps/Helper/src/lib/layers/target.js +202 -0
- package/dist/esm/apps/Helper/src/lib/layers/uc.d.ts +3 -0
- package/dist/esm/apps/Helper/src/lib/layers/uc.js +113 -0
- package/dist/esm/apps/Helper/src/lib/project.js +15 -17
- package/dist/esm/apps/Helper/src/lib/types.d.ts +3 -0
- package/dist/esm/apps/Helper/src/lib/types.js +1 -0
- package/dist/esm/apps/Helper/src/manifest.d.ts +20 -0
- package/dist/esm/apps/Helper/src/manifest.js +20 -0
- package/dist/esm/apps/Helper/src/ucds/CreateAppUCD.d.ts +7 -0
- package/dist/esm/apps/Helper/src/ucds/CreateAppUCD.js +101 -0
- package/dist/esm/apps/Helper/src/ucds/CreateProductUCD.d.ts +7 -0
- package/dist/esm/apps/Helper/src/ucds/CreateProductUCD.js +101 -0
- package/dist/esm/apps/Helper/src/ucds/CreateProjectUCD.d.ts +1 -17
- package/dist/esm/apps/Helper/src/ucds/CreateProjectUCD.js +40 -34
- package/dist/esm/apps/Helper/src/ucds/CreateTargetUCD.d.ts +9 -0
- package/dist/esm/apps/Helper/src/ucds/CreateTargetUCD.js +109 -0
- package/dist/esm/apps/Helper/src/ucds/CreateUCUCD.d.ts +8 -0
- package/dist/esm/apps/Helper/src/ucds/CreateUCUCD.js +87 -0
- package/dist/esm/apps/Helper/src/ucds/DeleteGeneratedAppsTestsUCD.d.ts +1 -1
- package/dist/esm/apps/Helper/src/ucds/DeleteGeneratedAppsTestsUCD.js +1 -1
- package/dist/esm/apps/Helper/src/ucds/GenerateAppsTestsUCD.d.ts +1 -1
- package/dist/esm/apps/Helper/src/ucds/GenerateAppsTestsUCD.js +1 -1
- package/dist/esm/apps/Helper/src/ucds/TestAppUCD.d.ts +1 -1
- package/dist/esm/apps/Helper/src/ucds/TestAppUCD.js +1 -1
- package/dist/esm/convention.d.ts +16 -5
- package/dist/esm/convention.js +34 -10
- package/dist/esm/error/funcs.d.ts +2 -0
- package/dist/esm/error/funcs.js +20 -0
- package/dist/esm/error/index.d.ts +1 -1
- package/dist/esm/error/index.js +1 -1
- package/dist/esm/index.d.ts +2 -0
- package/dist/esm/index.js +2 -0
- package/dist/esm/index.node-test.d.ts +1 -1
- package/dist/esm/index.node-test.js +1 -1
- package/dist/esm/product/index.d.ts +1 -1
- package/dist/esm/product/index.js +1 -1
- package/dist/esm/product/workers/ProductUCsLoader.d.ts +8 -6
- package/dist/esm/product/workers/ProductUCsLoader.js +19 -5
- package/dist/esm/products/Helper/cli-node-core/container.d.ts +3 -0
- package/dist/esm/products/Helper/cli-node-core/container.js +26 -0
- package/dist/esm/products/Helper/cli-node-core/index.d.ts +1 -0
- package/dist/esm/products/Helper/cli-node-core/index.js +9 -0
- package/dist/esm/products/Helper/i18n.d.ts +101 -2
- package/dist/esm/products/Helper/targets/node-core-cli/container.d.ts +3 -0
- package/dist/esm/products/Helper/targets/node-core-cli/container.js +26 -0
- package/dist/esm/products/Helper/targets/node-core-cli/index.d.ts +1 -0
- package/dist/esm/products/Helper/targets/node-core-cli/index.js +9 -0
- package/dist/esm/std/SettingsManager.d.ts +3 -16
- package/dist/esm/std/SettingsManager.js +1 -16
- package/dist/esm/std/ShellCommandExecutor.d.ts +1 -1
- package/dist/esm/std/consts.js +4 -4
- package/dist/esm/std/impl/EnvSettingsManager.d.ts +5 -4
- package/dist/esm/std/impl/EnvSettingsManager.js +40 -62
- package/dist/esm/std/impl/FakeFSManager.d.ts +3 -1
- package/dist/esm/std/impl/FakeFSManager.js +3 -0
- package/dist/esm/std/impl/FakeShellCommandExecutor.d.ts +12 -0
- package/dist/esm/std/impl/FakeShellCommandExecutor.js +30 -0
- package/dist/esm/std/impl/StaticSettingsManager.d.ts +1 -1
- package/dist/esm/std/impl/StaticSettingsManager.js +3 -0
- package/dist/esm/std/index.d.ts +1 -0
- package/dist/esm/std/index.js +1 -0
- package/dist/esm/std/lib/settings.d.ts +5 -0
- package/dist/esm/std/lib/settings.js +39 -0
- package/dist/esm/target/edge-worker-hono-server/SyncEdgeWorkerHonoServerManager.d.ts +3 -1
- package/dist/esm/target/edge-worker-hono-server/SyncEdgeWorkerHonoServerManager.js +12 -7
- package/dist/esm/target/index.d.ts +1 -0
- package/dist/esm/target/index.js +1 -0
- package/dist/esm/target/lib/cli/CLIManager.d.ts +2 -2
- package/dist/esm/target/lib/client/consts.js +2 -1
- package/dist/esm/target/lib/entrypoint.d.ts +2 -0
- package/dist/esm/target/lib/entrypoint.js +1 -0
- package/dist/esm/target/lib/manifest.d.ts +13 -0
- package/dist/esm/target/lib/manifest.js +11 -0
- package/dist/esm/target/lib/mcp-server/MCPServerBooter.d.ts +2 -2
- package/dist/esm/target/lib/server/CustomerFacingErrorBuilder.js +6 -1
- package/dist/esm/target/lib/server/ServerBooter.d.ts +2 -2
- package/dist/esm/target/lib/server/ServerRequestHandler.js +6 -2
- package/dist/esm/target/lib/server/consts.js +2 -1
- package/dist/esm/target/lib/server-express/funcs.d.ts +2 -0
- package/dist/esm/target/lib/server-express/funcs.js +6 -0
- package/dist/esm/target/lib/server-hono/funcs.d.ts +2 -1
- package/dist/esm/target/lib/server-hono/funcs.js +7 -3
- package/dist/esm/target/node-express-server/NodeExpressServerManager.d.ts +3 -1
- package/dist/esm/target/node-express-server/NodeExpressServerManager.js +17 -12
- package/dist/esm/target/node-hono-server/NodeHonoServerManager.d.ts +3 -1
- package/dist/esm/target/node-hono-server/NodeHonoServerManager.js +15 -10
- package/dist/esm/target/node-stricli-cli/NodeStricliCLIManager.d.ts +3 -1
- package/dist/esm/target/node-stricli-cli/NodeStricliCLIManager.js +9 -5
- package/dist/esm/testing/impl/NodeAppTesterConfigurator.d.ts +15 -0
- package/dist/esm/testing/impl/NodeAppTesterConfigurator.js +68 -0
- package/dist/esm/testing/impl/VitestAppTestSuiteEmitter.d.ts +2 -0
- package/dist/esm/testing/impl/VitestAppTestSuiteEmitter.js +27 -10
- package/dist/esm/testing/impl/newNodeAppTester.js +3 -4
- package/dist/esm/testing/opts.d.ts +1 -1
- package/dist/esm/utils/ioc/bindCommon.d.ts +4 -4
- package/dist/esm/utils/ioc/bindCommon.js +17 -15
- package/dist/esm/utils/ioc/bindNodeCore.js +5 -0
- package/dist/esm/utils/ioc/bindServer.js +8 -2
- package/package.json +19 -18
- package/pnpm-workspace.yaml +0 -8
- package/tsconfig.build.examples.json +0 -8
- package/tsconfig.json +0 -36
- package/vitest.config.ts +0 -16
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
7
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
8
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
9
|
+
};
|
|
10
|
+
var __param = (this && this.__param) || function (paramIndex, decorator) {
|
|
11
|
+
return function (target, key) { decorator(target, key, paramIndex); }
|
|
12
|
+
};
|
|
13
|
+
import { inject, injectable } from 'inversify';
|
|
14
|
+
import { APP_NAME_PLACEHOLDER } from '../../../../convention.js';
|
|
15
|
+
import { TString } from '../../../../dt/index.js';
|
|
16
|
+
import { IllegalArgumentError } from '../../../../error/index.js';
|
|
17
|
+
import { EverybodyUCPolicy, } from '../../../../uc/index.js';
|
|
18
|
+
import { GIT_KEEP_FILE_NAME } from '../lib/consts.js';
|
|
19
|
+
import { successMessage } from '../lib/funcs.js';
|
|
20
|
+
import { AppInputFieldsDef } from '../lib/io.js';
|
|
21
|
+
import { files } from '../lib/layers/app.js';
|
|
22
|
+
import { SrcFilesGenerator } from '../lib/SrcFilesGenerator.js';
|
|
23
|
+
import { Manifest } from '../manifest.js';
|
|
24
|
+
let CreateAppClientMain = class CreateAppClientMain {
|
|
25
|
+
fsManager;
|
|
26
|
+
i18nManager;
|
|
27
|
+
logger;
|
|
28
|
+
srcFilesGenerator;
|
|
29
|
+
rootPath;
|
|
30
|
+
constructor(fsManager, i18nManager, logger, srcFilesGenerator) {
|
|
31
|
+
this.fsManager = fsManager;
|
|
32
|
+
this.i18nManager = i18nManager;
|
|
33
|
+
this.logger = logger;
|
|
34
|
+
this.srcFilesGenerator = srcFilesGenerator;
|
|
35
|
+
}
|
|
36
|
+
async exec({ uc }) {
|
|
37
|
+
const appsPath = uc.reqVal0('appsPath');
|
|
38
|
+
const appName = uc.reqVal0('appName');
|
|
39
|
+
this.rootPath = this.fsManager.path(appsPath, appName);
|
|
40
|
+
// TODO : Rollback the whole thing in case of failure
|
|
41
|
+
await this.assertNotExisting();
|
|
42
|
+
await this.createRootDir();
|
|
43
|
+
await this.srcFilesGenerator.exec({
|
|
44
|
+
files: files(appName),
|
|
45
|
+
rootPath: this.rootPath,
|
|
46
|
+
});
|
|
47
|
+
await this.rmGitKeep();
|
|
48
|
+
this.logger.info(successMessage('App'));
|
|
49
|
+
}
|
|
50
|
+
async assertNotExisting() {
|
|
51
|
+
if (!(await this.fsManager.exists(this.rootPath))) {
|
|
52
|
+
return;
|
|
53
|
+
}
|
|
54
|
+
throw new IllegalArgumentError(this.i18nManager.t('err_existing_app', {
|
|
55
|
+
vars: { appPath: this.rootPath },
|
|
56
|
+
}));
|
|
57
|
+
}
|
|
58
|
+
async createRootDir() {
|
|
59
|
+
this.logger.info('Creating root dir : %s', this.rootPath);
|
|
60
|
+
await this.fsManager.mkdir(this.rootPath, { recursive: true });
|
|
61
|
+
}
|
|
62
|
+
async rmGitKeep() {
|
|
63
|
+
const filePath = this.fsManager.path(this.rootPath, '..', GIT_KEEP_FILE_NAME);
|
|
64
|
+
if (!(await this.fsManager.exists(filePath))) {
|
|
65
|
+
return;
|
|
66
|
+
}
|
|
67
|
+
await this.fsManager.rm(filePath);
|
|
68
|
+
}
|
|
69
|
+
};
|
|
70
|
+
CreateAppClientMain = __decorate([
|
|
71
|
+
injectable(),
|
|
72
|
+
__param(0, inject('FSManager')),
|
|
73
|
+
__param(1, inject('I18nManager')),
|
|
74
|
+
__param(2, inject('Logger')),
|
|
75
|
+
__param(3, inject(SrcFilesGenerator)),
|
|
76
|
+
__metadata("design:paramtypes", [Object, Object, Object, SrcFilesGenerator])
|
|
77
|
+
], CreateAppClientMain);
|
|
78
|
+
export const CreateAppUCD = {
|
|
79
|
+
ext: {
|
|
80
|
+
cmd: {
|
|
81
|
+
mountAt: 'CreateApp',
|
|
82
|
+
},
|
|
83
|
+
},
|
|
84
|
+
io: {
|
|
85
|
+
i: {
|
|
86
|
+
fields: {
|
|
87
|
+
...AppInputFieldsDef,
|
|
88
|
+
appName: {
|
|
89
|
+
type: new TString().setExamples([APP_NAME_PLACEHOLDER]),
|
|
90
|
+
},
|
|
91
|
+
},
|
|
92
|
+
},
|
|
93
|
+
},
|
|
94
|
+
lifecycle: {
|
|
95
|
+
client: {
|
|
96
|
+
main: CreateAppClientMain,
|
|
97
|
+
policy: EverybodyUCPolicy,
|
|
98
|
+
},
|
|
99
|
+
},
|
|
100
|
+
metadata: Manifest.ucReg.CreateApp,
|
|
101
|
+
};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { ProductName } from '../../../../product/index.js';
|
|
2
|
+
import { type UCDef, type UCInputFieldValue } from '../../../../uc/index.js';
|
|
3
|
+
import { type ProductInput } from '../lib/io.js';
|
|
4
|
+
export interface CreateProductInput extends ProductInput {
|
|
5
|
+
productName: UCInputFieldValue<ProductName>;
|
|
6
|
+
}
|
|
7
|
+
export declare const CreateProductUCD: UCDef<CreateProductInput>;
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
7
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
8
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
9
|
+
};
|
|
10
|
+
var __param = (this && this.__param) || function (paramIndex, decorator) {
|
|
11
|
+
return function (target, key) { decorator(target, key, paramIndex); }
|
|
12
|
+
};
|
|
13
|
+
import { inject, injectable } from 'inversify';
|
|
14
|
+
import { PRODUCT_NAME_PLACEHOLDER } from '../../../../convention.js';
|
|
15
|
+
import { TString } from '../../../../dt/index.js';
|
|
16
|
+
import { IllegalArgumentError } from '../../../../error/index.js';
|
|
17
|
+
import { EverybodyUCPolicy, } from '../../../../uc/index.js';
|
|
18
|
+
import { GIT_KEEP_FILE_NAME } from '../lib/consts.js';
|
|
19
|
+
import { successMessage } from '../lib/funcs.js';
|
|
20
|
+
import { ProductInputFieldsDef } from '../lib/io.js';
|
|
21
|
+
import { files } from '../lib/layers/product.js';
|
|
22
|
+
import { SrcFilesGenerator } from '../lib/SrcFilesGenerator.js';
|
|
23
|
+
import { Manifest } from '../manifest.js';
|
|
24
|
+
let CreateProductClientMain = class CreateProductClientMain {
|
|
25
|
+
fsManager;
|
|
26
|
+
i18nManager;
|
|
27
|
+
logger;
|
|
28
|
+
srcFilesGenerator;
|
|
29
|
+
rootPath;
|
|
30
|
+
constructor(fsManager, i18nManager, logger, srcFilesGenerator) {
|
|
31
|
+
this.fsManager = fsManager;
|
|
32
|
+
this.i18nManager = i18nManager;
|
|
33
|
+
this.logger = logger;
|
|
34
|
+
this.srcFilesGenerator = srcFilesGenerator;
|
|
35
|
+
}
|
|
36
|
+
async exec({ uc }) {
|
|
37
|
+
const productsPath = uc.reqVal0('productsPath');
|
|
38
|
+
const productName = uc.reqVal0('productName');
|
|
39
|
+
this.rootPath = this.fsManager.path(productsPath, productName);
|
|
40
|
+
// TODO : Rollback the whole thing in case of failure
|
|
41
|
+
await this.assertNotExisting();
|
|
42
|
+
await this.createRootDir();
|
|
43
|
+
await this.srcFilesGenerator.exec({
|
|
44
|
+
files: files(productName),
|
|
45
|
+
rootPath: this.rootPath,
|
|
46
|
+
});
|
|
47
|
+
await this.rmGitKeep();
|
|
48
|
+
this.logger.info(successMessage('Product'));
|
|
49
|
+
}
|
|
50
|
+
async assertNotExisting() {
|
|
51
|
+
if (!(await this.fsManager.exists(this.rootPath))) {
|
|
52
|
+
return;
|
|
53
|
+
}
|
|
54
|
+
throw new IllegalArgumentError(this.i18nManager.t('err_existing_product', {
|
|
55
|
+
vars: { productPath: this.rootPath },
|
|
56
|
+
}));
|
|
57
|
+
}
|
|
58
|
+
async createRootDir() {
|
|
59
|
+
this.logger.info('Creating root dir : %s', this.rootPath);
|
|
60
|
+
await this.fsManager.mkdir(this.rootPath, { recursive: true });
|
|
61
|
+
}
|
|
62
|
+
async rmGitKeep() {
|
|
63
|
+
const filePath = this.fsManager.path(this.rootPath, '..', GIT_KEEP_FILE_NAME);
|
|
64
|
+
if (!(await this.fsManager.exists(filePath))) {
|
|
65
|
+
return;
|
|
66
|
+
}
|
|
67
|
+
await this.fsManager.rm(filePath);
|
|
68
|
+
}
|
|
69
|
+
};
|
|
70
|
+
CreateProductClientMain = __decorate([
|
|
71
|
+
injectable(),
|
|
72
|
+
__param(0, inject('FSManager')),
|
|
73
|
+
__param(1, inject('I18nManager')),
|
|
74
|
+
__param(2, inject('Logger')),
|
|
75
|
+
__param(3, inject(SrcFilesGenerator)),
|
|
76
|
+
__metadata("design:paramtypes", [Object, Object, Object, SrcFilesGenerator])
|
|
77
|
+
], CreateProductClientMain);
|
|
78
|
+
export const CreateProductUCD = {
|
|
79
|
+
ext: {
|
|
80
|
+
cmd: {
|
|
81
|
+
mountAt: 'CreateProduct',
|
|
82
|
+
},
|
|
83
|
+
},
|
|
84
|
+
io: {
|
|
85
|
+
i: {
|
|
86
|
+
fields: {
|
|
87
|
+
...ProductInputFieldsDef,
|
|
88
|
+
productName: {
|
|
89
|
+
type: new TString().setExamples([PRODUCT_NAME_PLACEHOLDER]),
|
|
90
|
+
},
|
|
91
|
+
},
|
|
92
|
+
},
|
|
93
|
+
},
|
|
94
|
+
lifecycle: {
|
|
95
|
+
client: {
|
|
96
|
+
main: CreateProductClientMain,
|
|
97
|
+
policy: EverybodyUCPolicy,
|
|
98
|
+
},
|
|
99
|
+
},
|
|
100
|
+
metadata: Manifest.ucReg.CreateProduct,
|
|
101
|
+
};
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { type DirPath, type FileName, type FreeTextShort, type Slug } from '../../../../dt/index.js';
|
|
2
|
-
import type
|
|
3
|
-
import { type UCDef, type UCInput, type UCInputFieldValue, type UCMain, type UCMainInput } from '../../../../uc/index.js';
|
|
2
|
+
import { type UCDef, type UCInput, type UCInputFieldValue } from '../../../../uc/index.js';
|
|
4
3
|
export interface CreateProjectInput extends UCInput {
|
|
5
4
|
initialCommit: UCInputFieldValue<FreeTextShort>;
|
|
6
5
|
outPath: UCInputFieldValue<DirPath>;
|
|
@@ -9,19 +8,4 @@ export interface CreateProjectInput extends UCInput {
|
|
|
9
8
|
scmBin: UCInputFieldValue<FileName>;
|
|
10
9
|
verbose: UCInputFieldValue<boolean>;
|
|
11
10
|
}
|
|
12
|
-
export declare class CreateProjectClientMain implements UCMain<CreateProjectInput> {
|
|
13
|
-
private fsManager;
|
|
14
|
-
private logger;
|
|
15
|
-
private shellCommandExecutor;
|
|
16
|
-
constructor(fsManager: FSManager, logger: Logger, shellCommandExecutor: ShellCommandExecutor);
|
|
17
|
-
exec({ uc }: UCMainInput<CreateProjectInput>): Promise<void>;
|
|
18
|
-
private assertBinPresence;
|
|
19
|
-
private commit;
|
|
20
|
-
private createConfigFiles;
|
|
21
|
-
private createDirs;
|
|
22
|
-
private createRootDir;
|
|
23
|
-
private initRepository;
|
|
24
|
-
private installDeps;
|
|
25
|
-
private runDevCmds;
|
|
26
|
-
}
|
|
27
11
|
export declare const CreateProjectUCD: UCDef<CreateProjectInput>;
|
|
@@ -15,16 +15,22 @@ import { APPS_ROOT_PATH, PRODUCTS_ROOT_PATH } from '../../../../convention.js';
|
|
|
15
15
|
import { TBoolean, TDirPath, TFileName, TFreeTextShort, TSlug, } from '../../../../dt/index.js';
|
|
16
16
|
import { IllegalArgumentError } from '../../../../error/index.js';
|
|
17
17
|
import { EverybodyUCPolicy, } from '../../../../uc/index.js';
|
|
18
|
-
import {
|
|
18
|
+
import { GIT_KEEP_FILE_NAME } from '../lib/consts.js';
|
|
19
|
+
import { successMessage } from '../lib/funcs.js';
|
|
20
|
+
import { files } from '../lib/layers/project.js';
|
|
21
|
+
import { SrcFilesGenerator } from '../lib/SrcFilesGenerator.js';
|
|
19
22
|
import { Manifest } from '../manifest.js';
|
|
20
23
|
let CreateProjectClientMain = class CreateProjectClientMain {
|
|
21
24
|
fsManager;
|
|
22
25
|
logger;
|
|
23
26
|
shellCommandExecutor;
|
|
24
|
-
|
|
27
|
+
srcFilesGenerator;
|
|
28
|
+
rootPath;
|
|
29
|
+
constructor(fsManager, logger, shellCommandExecutor, srcFilesGenerator) {
|
|
25
30
|
this.fsManager = fsManager;
|
|
26
31
|
this.logger = logger;
|
|
27
32
|
this.shellCommandExecutor = shellCommandExecutor;
|
|
33
|
+
this.srcFilesGenerator = srcFilesGenerator;
|
|
28
34
|
}
|
|
29
35
|
async exec({ uc }) {
|
|
30
36
|
const initialCommit = uc.reqVal0('initialCommit');
|
|
@@ -35,16 +41,19 @@ let CreateProjectClientMain = class CreateProjectClientMain {
|
|
|
35
41
|
const verbose = uc.reqVal0('verbose');
|
|
36
42
|
await this.assertBinPresence(pkgManagerBin);
|
|
37
43
|
await this.assertBinPresence(scmBin);
|
|
38
|
-
|
|
44
|
+
this.rootPath = this.fsManager.path(outPath, projectName);
|
|
39
45
|
// TODO : Rollback the whole thing in case of failure
|
|
40
|
-
await this.createRootDir(
|
|
41
|
-
await this.initRepository(scmBin,
|
|
42
|
-
await this.
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
await this.
|
|
47
|
-
this.
|
|
46
|
+
await this.createRootDir();
|
|
47
|
+
await this.initRepository(scmBin, verbose);
|
|
48
|
+
await this.srcFilesGenerator.exec({
|
|
49
|
+
files: files(projectName),
|
|
50
|
+
rootPath: this.rootPath,
|
|
51
|
+
});
|
|
52
|
+
await this.createDirs();
|
|
53
|
+
await this.installDeps(pkgManagerBin, verbose);
|
|
54
|
+
await this.commit(scmBin, initialCommit, verbose);
|
|
55
|
+
await this.runDevCmds(pkgManagerBin, verbose);
|
|
56
|
+
this.logger.info(successMessage('Project'));
|
|
48
57
|
}
|
|
49
58
|
async assertBinPresence(bin) {
|
|
50
59
|
try {
|
|
@@ -57,7 +66,7 @@ let CreateProjectClientMain = class CreateProjectClientMain {
|
|
|
57
66
|
throw new IllegalArgumentError(`'${bin}' seems missing. Is it installed on your machine ?`);
|
|
58
67
|
}
|
|
59
68
|
}
|
|
60
|
-
async commit(scmBin, initialCommit,
|
|
69
|
+
async commit(scmBin, initialCommit, verbose) {
|
|
61
70
|
this.logger.info('Committing');
|
|
62
71
|
const cmdArgs = [
|
|
63
72
|
['branch', '-M', 'master'],
|
|
@@ -67,54 +76,51 @@ let CreateProjectClientMain = class CreateProjectClientMain {
|
|
|
67
76
|
for await (const args of cmdArgs) {
|
|
68
77
|
await this.shellCommandExecutor.exec({
|
|
69
78
|
bin: scmBin,
|
|
70
|
-
opts: { args, cwd, streamData: verbose },
|
|
79
|
+
opts: { args, cwd: this.rootPath, streamData: verbose },
|
|
71
80
|
});
|
|
72
81
|
}
|
|
73
82
|
}
|
|
74
|
-
async
|
|
75
|
-
const files = projectFiles(projectName);
|
|
76
|
-
for await (const [fileName, content] of files) {
|
|
77
|
-
const path = this.fsManager.path(cwd, fileName);
|
|
78
|
-
await this.fsManager.touch(path, content);
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
|
-
async createDirs(cwd) {
|
|
83
|
+
async createDirs() {
|
|
82
84
|
this.logger.info('Creating apps and products directories');
|
|
83
85
|
const dirs = [APPS_ROOT_PATH, PRODUCTS_ROOT_PATH];
|
|
84
86
|
for await (const dirPath of dirs) {
|
|
85
|
-
const path = this.fsManager.path(
|
|
87
|
+
const path = this.fsManager.path(this.rootPath, ...dirPath);
|
|
86
88
|
await this.fsManager.mkdir(path, { recursive: true });
|
|
87
|
-
await this.fsManager.touch(this.fsManager.path(path,
|
|
89
|
+
await this.fsManager.touch(this.fsManager.path(path, GIT_KEEP_FILE_NAME), '');
|
|
88
90
|
}
|
|
89
91
|
}
|
|
90
|
-
async createRootDir(
|
|
91
|
-
this.logger.info('Creating root dir : %s',
|
|
92
|
-
await this.fsManager.mkdir(
|
|
92
|
+
async createRootDir() {
|
|
93
|
+
this.logger.info('Creating root dir : %s', this.rootPath);
|
|
94
|
+
await this.fsManager.mkdir(this.rootPath, { recursive: true });
|
|
93
95
|
}
|
|
94
|
-
async initRepository(scmBin,
|
|
96
|
+
async initRepository(scmBin, verbose) {
|
|
95
97
|
const cmd = 'init';
|
|
96
98
|
this.logger.info('Initializing repository : %s %s', scmBin, cmd);
|
|
97
99
|
await this.shellCommandExecutor.exec({
|
|
98
100
|
bin: scmBin,
|
|
99
|
-
opts: { args: [cmd], cwd, streamData: verbose },
|
|
101
|
+
opts: { args: [cmd], cwd: this.rootPath, streamData: verbose },
|
|
100
102
|
});
|
|
101
103
|
}
|
|
102
|
-
async installDeps(pkgManagerBin,
|
|
104
|
+
async installDeps(pkgManagerBin, verbose) {
|
|
103
105
|
const cmd = 'install';
|
|
104
106
|
this.logger.info('Installing dependencies : %s %s', pkgManagerBin, cmd);
|
|
105
107
|
await this.shellCommandExecutor.exec({
|
|
106
108
|
bin: pkgManagerBin,
|
|
107
|
-
opts: { args: [cmd], cwd, streamData: verbose },
|
|
109
|
+
opts: { args: [cmd], cwd: this.rootPath, streamData: verbose },
|
|
108
110
|
});
|
|
109
111
|
}
|
|
110
|
-
async runDevCmds(pkgManagerBin,
|
|
112
|
+
async runDevCmds(pkgManagerBin, verbose) {
|
|
111
113
|
const cmd = 'run';
|
|
112
114
|
const scripts = ['lint', 'test'];
|
|
113
115
|
for await (const script of scripts) {
|
|
114
116
|
this.logger.info('Running dev command : %s %s %s', pkgManagerBin, cmd, script);
|
|
115
117
|
await this.shellCommandExecutor.exec({
|
|
116
118
|
bin: pkgManagerBin,
|
|
117
|
-
opts: {
|
|
119
|
+
opts: {
|
|
120
|
+
args: [cmd, script],
|
|
121
|
+
cwd: this.rootPath,
|
|
122
|
+
streamData: verbose,
|
|
123
|
+
},
|
|
118
124
|
});
|
|
119
125
|
}
|
|
120
126
|
}
|
|
@@ -124,9 +130,9 @@ CreateProjectClientMain = __decorate([
|
|
|
124
130
|
__param(0, inject('FSManager')),
|
|
125
131
|
__param(1, inject('Logger')),
|
|
126
132
|
__param(2, inject('ShellCommandExecutor')),
|
|
127
|
-
|
|
133
|
+
__param(3, inject(SrcFilesGenerator)),
|
|
134
|
+
__metadata("design:paramtypes", [Object, Object, Object, SrcFilesGenerator])
|
|
128
135
|
], CreateProjectClientMain);
|
|
129
|
-
export { CreateProjectClientMain };
|
|
130
136
|
export const CreateProjectUCD = {
|
|
131
137
|
ext: {
|
|
132
138
|
cmd: {
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { ProductName } from '../../../../product/index.js';
|
|
2
|
+
import { type TargetName } from '../../../../target/index.js';
|
|
3
|
+
import { type UCDef, type UCInputFieldValue } from '../../../../uc/index.js';
|
|
4
|
+
import { type ProductInput } from '../lib/io.js';
|
|
5
|
+
export interface CreateTargetInput extends ProductInput {
|
|
6
|
+
productName: UCInputFieldValue<ProductName>;
|
|
7
|
+
targetName: UCInputFieldValue<TargetName>;
|
|
8
|
+
}
|
|
9
|
+
export declare const CreateTargetUCD: UCDef<CreateTargetInput>;
|
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
7
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
8
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
9
|
+
};
|
|
10
|
+
var __param = (this && this.__param) || function (paramIndex, decorator) {
|
|
11
|
+
return function (target, key) { decorator(target, key, paramIndex); }
|
|
12
|
+
};
|
|
13
|
+
import { inject, injectable } from 'inversify';
|
|
14
|
+
import { PRODUCT_NAME_PLACEHOLDER, PRODUCT_TARGETS_DIR_NAME, TARGET_NAME_PLACEHOLDER, } from '../../../../convention.js';
|
|
15
|
+
import { TString } from '../../../../dt/index.js';
|
|
16
|
+
import { IllegalArgumentError } from '../../../../error/index.js';
|
|
17
|
+
import { TARGETS } from '../../../../target/index.js';
|
|
18
|
+
import { EverybodyUCPolicy, } from '../../../../uc/index.js';
|
|
19
|
+
import { successMessage } from '../lib/funcs.js';
|
|
20
|
+
import { ProductInputFieldsDef } from '../lib/io.js';
|
|
21
|
+
import { files } from '../lib/layers/target.js';
|
|
22
|
+
import { SrcFilesGenerator } from '../lib/SrcFilesGenerator.js';
|
|
23
|
+
import { Manifest } from '../manifest.js';
|
|
24
|
+
let CreateTargetClientMain = class CreateTargetClientMain {
|
|
25
|
+
fsManager;
|
|
26
|
+
i18nManager;
|
|
27
|
+
logger;
|
|
28
|
+
srcFilesGenerator;
|
|
29
|
+
rootPath;
|
|
30
|
+
constructor(fsManager, i18nManager, logger, srcFilesGenerator) {
|
|
31
|
+
this.fsManager = fsManager;
|
|
32
|
+
this.i18nManager = i18nManager;
|
|
33
|
+
this.logger = logger;
|
|
34
|
+
this.srcFilesGenerator = srcFilesGenerator;
|
|
35
|
+
}
|
|
36
|
+
async exec({ uc }) {
|
|
37
|
+
const productsPath = uc.reqVal0('productsPath');
|
|
38
|
+
const productName = uc.reqVal0('productName');
|
|
39
|
+
const targetName = uc.reqVal0('targetName');
|
|
40
|
+
this.rootPath = this.fsManager.path(productsPath, productName, PRODUCT_TARGETS_DIR_NAME, targetName);
|
|
41
|
+
// TODO : Rollback the whole thing in case of failure
|
|
42
|
+
const filesToGenerate = files(targetName);
|
|
43
|
+
if (filesToGenerate.size === 0) {
|
|
44
|
+
throw new IllegalArgumentError(this.i18nManager.t('err_target_generator_not_available'));
|
|
45
|
+
}
|
|
46
|
+
await this.assertNotExisting();
|
|
47
|
+
await this.createRootDir();
|
|
48
|
+
await this.srcFilesGenerator.exec({
|
|
49
|
+
files: files(targetName),
|
|
50
|
+
rootPath: this.rootPath,
|
|
51
|
+
});
|
|
52
|
+
this.logger.info(successMessage('Target'));
|
|
53
|
+
}
|
|
54
|
+
async assertNotExisting() {
|
|
55
|
+
if (!(await this.fsManager.exists(this.rootPath))) {
|
|
56
|
+
return;
|
|
57
|
+
}
|
|
58
|
+
throw new IllegalArgumentError(this.i18nManager.t('err_existing_target', {
|
|
59
|
+
vars: { targetPath: this.rootPath },
|
|
60
|
+
}));
|
|
61
|
+
}
|
|
62
|
+
async createRootDir() {
|
|
63
|
+
this.logger.info('Creating root dir : %s', this.rootPath);
|
|
64
|
+
if (await this.fsManager.exists(this.rootPath)) {
|
|
65
|
+
return;
|
|
66
|
+
}
|
|
67
|
+
await this.fsManager.mkdir(this.rootPath, { recursive: true });
|
|
68
|
+
}
|
|
69
|
+
};
|
|
70
|
+
CreateTargetClientMain = __decorate([
|
|
71
|
+
injectable(),
|
|
72
|
+
__param(0, inject('FSManager')),
|
|
73
|
+
__param(1, inject('I18nManager')),
|
|
74
|
+
__param(2, inject('Logger')),
|
|
75
|
+
__param(3, inject(SrcFilesGenerator)),
|
|
76
|
+
__metadata("design:paramtypes", [Object, Object, Object, SrcFilesGenerator])
|
|
77
|
+
], CreateTargetClientMain);
|
|
78
|
+
export const CreateTargetUCD = {
|
|
79
|
+
ext: {
|
|
80
|
+
cmd: {
|
|
81
|
+
mountAt: 'CreateTarget',
|
|
82
|
+
},
|
|
83
|
+
},
|
|
84
|
+
io: {
|
|
85
|
+
i: {
|
|
86
|
+
fields: {
|
|
87
|
+
...ProductInputFieldsDef,
|
|
88
|
+
productName: {
|
|
89
|
+
type: new TString().setExamples([PRODUCT_NAME_PLACEHOLDER]),
|
|
90
|
+
},
|
|
91
|
+
targetName: {
|
|
92
|
+
type: new TString()
|
|
93
|
+
.setOptions(Object.keys(TARGETS).map((t) => ({
|
|
94
|
+
label: t,
|
|
95
|
+
value: t,
|
|
96
|
+
})))
|
|
97
|
+
.setExamples([TARGET_NAME_PLACEHOLDER]),
|
|
98
|
+
},
|
|
99
|
+
},
|
|
100
|
+
},
|
|
101
|
+
},
|
|
102
|
+
lifecycle: {
|
|
103
|
+
client: {
|
|
104
|
+
main: CreateTargetClientMain,
|
|
105
|
+
policy: EverybodyUCPolicy,
|
|
106
|
+
},
|
|
107
|
+
},
|
|
108
|
+
metadata: Manifest.ucReg.CreateTarget,
|
|
109
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { AppName } from '../../../../app/index.js';
|
|
2
|
+
import { type UCDef, type UCInputFieldValue, type UCName } from '../../../../uc/index.js';
|
|
3
|
+
import { type AppInput } from '../lib/io.js';
|
|
4
|
+
export interface CreateUCInput extends AppInput {
|
|
5
|
+
appName: UCInputFieldValue<AppName>;
|
|
6
|
+
ucName: UCInputFieldValue<UCName>;
|
|
7
|
+
}
|
|
8
|
+
export declare const CreateUCUCD: UCDef<CreateUCInput>;
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
7
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
8
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
9
|
+
};
|
|
10
|
+
var __param = (this && this.__param) || function (paramIndex, decorator) {
|
|
11
|
+
return function (target, key) { decorator(target, key, paramIndex); }
|
|
12
|
+
};
|
|
13
|
+
import { inject, injectable } from 'inversify';
|
|
14
|
+
import { APP_NAME_PLACEHOLDER, APP_SRC_DIR_NAME, APP_SRC_UCDS_DIR_NAME, UC_NAME_PLACEHOLDER, } from '../../../../convention.js';
|
|
15
|
+
import { TString } from '../../../../dt/index.js';
|
|
16
|
+
import { EverybodyUCPolicy, } from '../../../../uc/index.js';
|
|
17
|
+
import { successMessage } from '../lib/funcs.js';
|
|
18
|
+
import { AppInputFieldsDef } from '../lib/io.js';
|
|
19
|
+
import { files } from '../lib/layers/uc.js';
|
|
20
|
+
import { SrcFilesGenerator } from '../lib/SrcFilesGenerator.js';
|
|
21
|
+
import { Manifest } from '../manifest.js';
|
|
22
|
+
let CreateUCClientMain = class CreateUCClientMain {
|
|
23
|
+
fsManager;
|
|
24
|
+
logger;
|
|
25
|
+
srcFilesGenerator;
|
|
26
|
+
rootPath;
|
|
27
|
+
constructor(fsManager, logger, srcFilesGenerator) {
|
|
28
|
+
this.fsManager = fsManager;
|
|
29
|
+
this.logger = logger;
|
|
30
|
+
this.srcFilesGenerator = srcFilesGenerator;
|
|
31
|
+
}
|
|
32
|
+
async exec({ uc }) {
|
|
33
|
+
const appsPath = uc.reqVal0('appsPath');
|
|
34
|
+
const appName = uc.reqVal0('appName');
|
|
35
|
+
const ucName = uc.reqVal0('ucName');
|
|
36
|
+
this.rootPath = this.fsManager.path(appsPath, appName, APP_SRC_DIR_NAME, APP_SRC_UCDS_DIR_NAME);
|
|
37
|
+
// TODO : Rollback the whole thing in case of failure
|
|
38
|
+
await this.createRootDir();
|
|
39
|
+
await this.srcFilesGenerator.exec({
|
|
40
|
+
files: files(ucName),
|
|
41
|
+
rootPath: this.rootPath,
|
|
42
|
+
});
|
|
43
|
+
this.logger.info(successMessage('Use case'));
|
|
44
|
+
this.logger.info('You can now register the use case in the App Manifest');
|
|
45
|
+
}
|
|
46
|
+
async createRootDir() {
|
|
47
|
+
this.logger.info('Creating root dir : %s', this.rootPath);
|
|
48
|
+
if (await this.fsManager.exists(this.rootPath)) {
|
|
49
|
+
return;
|
|
50
|
+
}
|
|
51
|
+
await this.fsManager.mkdir(this.rootPath, { recursive: true });
|
|
52
|
+
}
|
|
53
|
+
};
|
|
54
|
+
CreateUCClientMain = __decorate([
|
|
55
|
+
injectable(),
|
|
56
|
+
__param(0, inject('FSManager')),
|
|
57
|
+
__param(1, inject('Logger')),
|
|
58
|
+
__param(2, inject(SrcFilesGenerator)),
|
|
59
|
+
__metadata("design:paramtypes", [Object, Object, SrcFilesGenerator])
|
|
60
|
+
], CreateUCClientMain);
|
|
61
|
+
export const CreateUCUCD = {
|
|
62
|
+
ext: {
|
|
63
|
+
cmd: {
|
|
64
|
+
mountAt: 'CreateUC',
|
|
65
|
+
},
|
|
66
|
+
},
|
|
67
|
+
io: {
|
|
68
|
+
i: {
|
|
69
|
+
fields: {
|
|
70
|
+
...AppInputFieldsDef,
|
|
71
|
+
appName: {
|
|
72
|
+
type: new TString().setExamples([APP_NAME_PLACEHOLDER]),
|
|
73
|
+
},
|
|
74
|
+
ucName: {
|
|
75
|
+
type: new TString().setExamples([UC_NAME_PLACEHOLDER]),
|
|
76
|
+
},
|
|
77
|
+
},
|
|
78
|
+
},
|
|
79
|
+
},
|
|
80
|
+
lifecycle: {
|
|
81
|
+
client: {
|
|
82
|
+
main: CreateUCClientMain,
|
|
83
|
+
policy: EverybodyUCPolicy,
|
|
84
|
+
},
|
|
85
|
+
},
|
|
86
|
+
metadata: Manifest.ucReg.CreateUC,
|
|
87
|
+
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type UCDef } from '../../../../uc/index.js';
|
|
2
|
-
import { type AppInput } from '../lib/
|
|
2
|
+
import { type AppInput } from '../lib/io.js';
|
|
3
3
|
export interface DeleteGeneratedAppsTestsInput extends AppInput {
|
|
4
4
|
}
|
|
5
5
|
export declare const DeleteGeneratedAppsTestsUCD: UCDef<DeleteGeneratedAppsTestsInput>;
|
|
@@ -14,7 +14,7 @@ import { inject, injectable } from 'inversify';
|
|
|
14
14
|
import { AppSrcBrowser } from '../../../../app/index.js';
|
|
15
15
|
import { APP_TEST_DIR_NAME, APP_TEST_MAIN_FILE_NAME, } from '../../../../convention.js';
|
|
16
16
|
import { EverybodyUCPolicy, } from '../../../../uc/index.js';
|
|
17
|
-
import { AppInputFieldsDef } from '../lib/
|
|
17
|
+
import { AppInputFieldsDef } from '../lib/io.js';
|
|
18
18
|
import { Manifest } from '../manifest.js';
|
|
19
19
|
let DeleteGeneratedAppsTestsClientMain = class DeleteGeneratedAppsTestsClientMain {
|
|
20
20
|
appSrcBrowser;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type FilePath, type HostPort, type UIntDuration } from '../../../../dt/index.js';
|
|
2
2
|
import { type UCDef, type UCInputFieldValue } from '../../../../uc/index.js';
|
|
3
|
-
import { type AppInput } from '../lib/
|
|
3
|
+
import { type AppInput } from '../lib/io.js';
|
|
4
4
|
declare const DEP_MAPPING_SEP = "::";
|
|
5
5
|
type DepMapping = `${FilePath}${typeof DEP_MAPPING_SEP}${FilePath}`;
|
|
6
6
|
export interface GenerateAppsTestsInput extends AppInput {
|
|
@@ -14,7 +14,7 @@ import { inject, injectable } from 'inversify';
|
|
|
14
14
|
import { AppSrcBrowser } from '../../../../app/index.js';
|
|
15
15
|
import { THostPort, TString, TUIntDuration, } from '../../../../dt/index.js';
|
|
16
16
|
import { EverybodyUCPolicy, } from '../../../../uc/index.js';
|
|
17
|
-
import { AppInputFieldsDef } from '../lib/
|
|
17
|
+
import { AppInputFieldsDef } from '../lib/io.js';
|
|
18
18
|
import { Manifest } from '../manifest.js';
|
|
19
19
|
const DEP_MAPPING_SEP = '::';
|
|
20
20
|
class TDepMapping extends TString {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { AppName } from '../../../../app/index.js';
|
|
2
2
|
import { type UCDef, type UCInputFieldValue, type UCName } from '../../../../uc/index.js';
|
|
3
|
-
import { type AppInput } from '../lib/
|
|
3
|
+
import { type AppInput } from '../lib/io.js';
|
|
4
4
|
export interface TestAppInput extends AppInput {
|
|
5
5
|
appName: UCInputFieldValue<AppName>;
|
|
6
6
|
only: UCInputFieldValue<UCName>;
|
|
@@ -16,7 +16,7 @@ import { TBoolean, TString } from '../../../../dt/index.js';
|
|
|
16
16
|
import { IllegalArgumentError } from '../../../../error/index.js';
|
|
17
17
|
import { SimpleHTMLAppTestReportEmitter } from '../../../../testing/impl/SimpleHTMLAppTestReportEmitter.js';
|
|
18
18
|
import { EverybodyUCPolicy, } from '../../../../uc/index.js';
|
|
19
|
-
import { AppInputFieldsDef } from '../lib/
|
|
19
|
+
import { AppInputFieldsDef } from '../lib/io.js';
|
|
20
20
|
import { Manifest } from '../manifest.js';
|
|
21
21
|
let TestAppClientMain = class TestAppClientMain {
|
|
22
22
|
appTestSuiteRunner;
|