node-cli-tester 21.0.18 → 21.0.19
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/browser/package.json +1 -1
- package/browser-prod/package.json +1 -1
- package/lib/build-info._auto-generated_.d.ts +1 -1
- package/lib/build-info._auto-generated_.js +1 -1
- package/lib/package.json +1 -1
- package/lib-prod/base-project-structure.backend.js +69 -72
- package/lib-prod/build-info._auto-generated_.js +26 -14
- package/lib-prod/cli-test.backend.js +113 -132
- package/lib-prod/env/env.angular-node-app.js +66 -130
- package/lib-prod/env/env.docs-webapp.js +66 -130
- package/lib-prod/env/env.electron-app.js +66 -130
- package/lib-prod/env/env.mobile-app.js +66 -130
- package/lib-prod/env/env.npm-lib-and-cli-tool.js +66 -130
- package/lib-prod/env/env.vscode-plugin.js +66 -130
- package/lib-prod/env/index.js +6 -6
- package/lib-prod/index._auto-generated_.js +5 -0
- package/lib-prod/index.js +6 -10
- package/lib-prod/meta-content-md.backend.js +223 -216
- package/lib-prod/migrations/index.js +2 -1
- package/lib-prod/migrations/migrations_index._auto-generated_.js +3 -0
- package/lib-prod/node-cli-tester.js +196 -193
- package/lib-prod/package.json +1 -1
- package/lib-prod/spec-templates.backend.js +45 -50
- package/lib-prod/start.backend.js +22 -13
- package/package.json +1 -1
- package/websql/package.json +1 -1
- package/websql-prod/package.json +1 -1
package/lib-prod/index.js
CHANGED
|
@@ -1,10 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
export {
|
|
6
|
-
|
|
7
|
-
NodeCliTester,
|
|
8
|
-
TestTemplates,
|
|
9
|
-
run
|
|
10
|
-
};
|
|
1
|
+
export { NodeCliTester } from './node-cli-tester';
|
|
2
|
+
//#region @backend
|
|
3
|
+
export { TestTemplates } from './spec-templates.backend';
|
|
4
|
+
export { CliTest } from './cli-test.backend';
|
|
5
|
+
export { run } from './start.backend';
|
|
6
|
+
//#endregion
|
|
@@ -1,182 +1,186 @@
|
|
|
1
|
-
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
1
|
+
//#region imports
|
|
2
|
+
import * as glob from 'glob';
|
|
3
|
+
import { path, ___NS__first, ___NS__isObject, ___NS__keys, ___NS__maxBy, ___NS__merge, ___NS__minBy, Utils__NS__uniqArray } from 'tnp-core/lib-prod';
|
|
4
|
+
import { config } from 'tnp-core/lib-prod';
|
|
5
|
+
import { BaseProject as Project, Helpers__NS__createSymLink, Helpers__NS__error, Helpers__NS__exists, Helpers__NS__isFolder, Helpers__NS__log, Helpers__NS__mkdirp, Helpers__NS__parse, Helpers__NS__readFile, Helpers__NS__removeFolderIfExists, Helpers__NS__stringify, Helpers__NS__writeFile } from 'tnp-helpers/lib-prod';
|
|
6
|
+
import { CLASS } from 'typescript-class-helpers/lib-prod';
|
|
7
|
+
import { BaseProjectStructure } from './base-project-structure.backend';
|
|
8
|
+
//#endregion
|
|
9
|
+
/**
|
|
10
|
+
* Special forma of .md for keeping metadata, testfile, and test template for file
|
|
11
|
+
*/
|
|
12
|
+
export class MetaMd {
|
|
13
|
+
//#region static fields
|
|
14
|
+
static { this.JSON_PART = '@jsonPart'; }
|
|
15
|
+
static { this.FILE_CONTENT_PART = '@fileContentPart'; }
|
|
16
|
+
static { this.TEST_PART = '@testPart'; }
|
|
17
|
+
//#region static fields / create
|
|
18
|
+
static async create(json, fileContent, testContent) {
|
|
19
|
+
return await create((___NS__isObject(json) ? Helpers__NS__stringify(json) : json), fileContent, testContent);
|
|
20
|
+
}
|
|
21
|
+
//#endregion
|
|
22
|
+
//#region static fields / preserve file
|
|
23
|
+
static async preserveFiles(originalAnyTypeFiles, destinationFolder, editorCwd, foundProjectsFn = (a) => a, baseProjectsStructurePath, // navi-cli folder or current folder,
|
|
24
|
+
overrideThisFileName = void 0, overrideTimehash = void 0) {
|
|
25
|
+
const properDestName = overrideThisFileName ? overrideThisFileName :
|
|
26
|
+
`${path.basename(___NS__first(originalAnyTypeFiles))}.${config.file.meta_config_md}`; // TODO later menu to confirm name
|
|
27
|
+
if (!Helpers__NS__isFolder(destinationFolder)) {
|
|
28
|
+
Helpers__NS__error(`[tnp-helpers][meta-content-md] Destination folder "${destinationFolder}"
|
|
27
29
|
is not a folder`, false, true);
|
|
30
|
+
}
|
|
31
|
+
let foundedProjectsInPath = resolveFoundedProject(originalAnyTypeFiles, editorCwd, foundProjectsFn);
|
|
32
|
+
const mostBaseLocationFound = ___NS__minBy(foundedProjectsInPath, p => p.location.length).location;
|
|
33
|
+
// console.log(foundedProjectsInPath.map(p => p.location))
|
|
34
|
+
const projects = foundedProjectsInPath
|
|
35
|
+
.reduce((a, b) => {
|
|
36
|
+
const baseStructureHash = BaseProjectStructure.generate(b).insideIfNotExists(baseProjectsStructurePath);
|
|
37
|
+
return ___NS__merge(a, {
|
|
38
|
+
[path.join(path.basename(mostBaseLocationFound), b.location.replace(mostBaseLocationFound, ''))]: {
|
|
39
|
+
githash: b.git.lastCommitHash(),
|
|
40
|
+
name: b.name,
|
|
41
|
+
baseStructureHash,
|
|
42
|
+
}
|
|
43
|
+
});
|
|
44
|
+
}, {});
|
|
45
|
+
const timeHash = overrideTimehash ? overrideTimehash : (+new Date).toString(36);
|
|
46
|
+
const c = await MetaMd.create({
|
|
47
|
+
orgFileBasenames: originalAnyTypeFiles.map(a => path.basename(a)),
|
|
48
|
+
orgRelativePathes: originalAnyTypeFiles.map(a => {
|
|
49
|
+
return path.join(path.basename(mostBaseLocationFound), a.replace(mostBaseLocationFound, ''));
|
|
50
|
+
}),
|
|
51
|
+
projects,
|
|
52
|
+
firstProjectBasename: path.basename(mostBaseLocationFound),
|
|
53
|
+
timeHash,
|
|
54
|
+
}, originalAnyTypeFiles.map(a => Helpers__NS__readFile(a)));
|
|
55
|
+
Helpers__NS__writeFile(path.join(destinationFolder, properDestName), c);
|
|
56
|
+
}
|
|
57
|
+
//#endregion
|
|
58
|
+
async addFiles(newFilesPathes, destinationFolder, editorCwd, foundProjectFn = void 0, baseProjectsStructurePath) {
|
|
59
|
+
let foundedProjectsInPath = resolveFoundedProject(newFilesPathes, editorCwd, foundProjectFn);
|
|
60
|
+
const mostBaseLocationFound = ___NS__minBy(foundedProjectsInPath, p => p.location.length).location;
|
|
61
|
+
newFilesPathes = Utils__NS__uniqArray([
|
|
62
|
+
...newFilesPathes,
|
|
63
|
+
...this.readonlyMetaJson.orgRelativePathes.map(a => {
|
|
64
|
+
return path.join(path.dirname(mostBaseLocationFound), a);
|
|
65
|
+
}),
|
|
66
|
+
]);
|
|
67
|
+
newFilesPathes.forEach(f => {
|
|
68
|
+
if (!Helpers__NS__exists(f)) {
|
|
69
|
+
Helpers__NS__error(`File doesn't exists`, false, true);
|
|
70
|
+
}
|
|
71
|
+
});
|
|
72
|
+
await MetaMd.preserveFiles(newFilesPathes, destinationFolder, editorCwd, foundProjectFn, baseProjectsStructurePath, path.basename(this.filePath), this.readonlyMetaJson.timeHash);
|
|
28
73
|
}
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
74
|
+
//#region static fields / handle instance from meta-content.md file
|
|
75
|
+
static instanceFrom(filePath) {
|
|
76
|
+
return new MetaMd(filePath);
|
|
77
|
+
}
|
|
78
|
+
static allInstancesFrom(folderPath) {
|
|
79
|
+
return glob.sync(`${folderPath}/*.${config.file.meta_config_md}`).map(f => {
|
|
80
|
+
return MetaMd.instanceFrom(f);
|
|
81
|
+
});
|
|
82
|
+
}
|
|
83
|
+
//#endregion
|
|
84
|
+
//#endregion
|
|
85
|
+
//#region getters
|
|
86
|
+
get json() {
|
|
87
|
+
const content = Helpers__NS__readFile(this.filePath) || '';
|
|
88
|
+
try {
|
|
89
|
+
const extracted = ___NS__first(extract(content, MetaMd.JSON_PART));
|
|
90
|
+
const parsed = Helpers__NS__parse(extracted, true);
|
|
91
|
+
return parsed;
|
|
92
|
+
}
|
|
93
|
+
catch (error) {
|
|
94
|
+
return {};
|
|
38
95
|
}
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
const extracted = extract(content, MetaMd.FILE_CONTENT_PART)[i];
|
|
106
|
-
return extracted;
|
|
107
|
-
}
|
|
108
|
-
get basename() {
|
|
109
|
-
return path.basename(this.filePath);
|
|
110
|
-
}
|
|
111
|
-
get dirname() {
|
|
112
|
-
return path.dirname(this.filePath);
|
|
113
|
-
}
|
|
114
|
-
//#endregion
|
|
115
|
-
//#region recreate files/content/env before any tests
|
|
116
|
-
/**
|
|
117
|
-
* recate original files before any unit/intergration test
|
|
118
|
-
*/
|
|
119
|
-
recreate(testCwd, cwdProj, ProjectClass = Project, onlyIfNotExists = false) {
|
|
120
|
-
const hashDir = path.join(testCwd, this.json.timeHash);
|
|
121
|
-
if (onlyIfNotExists && Helpers__NS__exists(hashDir)) {
|
|
122
|
-
return;
|
|
123
|
-
}
|
|
124
|
-
Helpers__NS__removeFolderIfExists(hashDir);
|
|
125
|
-
Helpers__NS__mkdirp(hashDir);
|
|
126
|
-
const firstToFind = this.json.projects[this.json.firstProjectBasename].baseStructureHash;
|
|
127
|
-
const allBaseStructures = BaseProjectStructure.allBaseStructures(cwdProj);
|
|
128
|
-
const baseStructure = allBaseStructures.find((p) => p.baseStructureHash === firstToFind);
|
|
129
|
-
if (!baseStructure) {
|
|
130
|
-
Helpers__NS__error(`[node-cli-test][regenerate] base structure was not generated for ${firstToFind}`, false, true);
|
|
131
|
-
}
|
|
132
|
-
baseStructure.copyto(hashDir);
|
|
133
|
-
___NS__keys(this.json.projects).filter((key) => key !== this.json.firstProjectBasename).map((key) => {
|
|
134
|
-
const baseStructureHashChild = this.json.projects[key].baseStructureHash;
|
|
135
|
-
const childBaseStruct = allBaseStructures.find((p) => p.baseStructureHash === baseStructureHashChild);
|
|
136
|
-
if (childBaseStruct) {
|
|
137
|
-
childBaseStruct.copyto(path.join(
|
|
138
|
-
hashDir,
|
|
139
|
-
path.dirname(key)
|
|
140
|
-
), path.basename(key));
|
|
141
|
-
}
|
|
142
|
-
});
|
|
143
|
-
this.readonlyMetaJson.orgRelativePathes.forEach((f, i) => {
|
|
144
|
-
const fileToWritePath = path.join(hashDir, f);
|
|
145
|
-
Helpers__NS__writeFile(fileToWritePath, this.fileContentByIndex(i));
|
|
146
|
-
});
|
|
147
|
-
const proj = ProjectClass.ins.From(path.join(hashDir, this.readonlyMetaJson.firstProjectBasename));
|
|
148
|
-
const linksToLInk = [];
|
|
149
|
-
linksToLInk.forEach((l) => {
|
|
150
|
-
const source = path.resolve(path.join(proj.location, l.relativeLinkFrom));
|
|
151
|
-
if (Helpers__NS__exists(source)) {
|
|
152
|
-
const dest = path.resolve(path.join(proj.location, l.relativePath));
|
|
153
|
-
Helpers__NS__createSymLink(source, dest);
|
|
154
|
-
} else {
|
|
155
|
-
Helpers__NS__log(`[cli-tester][recreate-env] not exist ${source}`);
|
|
156
|
-
}
|
|
157
|
-
});
|
|
158
|
-
}
|
|
159
|
-
//#endregion
|
|
96
|
+
}
|
|
97
|
+
get readonlyMetaJson() {
|
|
98
|
+
return Object.freeze(this.json);
|
|
99
|
+
}
|
|
100
|
+
fileContentByIndex(i) {
|
|
101
|
+
const content = Helpers__NS__readFile(this.filePath) || '';
|
|
102
|
+
const extracted = extract(content, MetaMd.FILE_CONTENT_PART)[i];
|
|
103
|
+
return extracted;
|
|
104
|
+
}
|
|
105
|
+
get basename() {
|
|
106
|
+
return path.basename(this.filePath);
|
|
107
|
+
}
|
|
108
|
+
get dirname() {
|
|
109
|
+
return path.dirname(this.filePath);
|
|
110
|
+
}
|
|
111
|
+
//#endregion
|
|
112
|
+
//#region constructor
|
|
113
|
+
constructor(filePath) {
|
|
114
|
+
this.filePath = filePath;
|
|
115
|
+
}
|
|
116
|
+
//#endregion
|
|
117
|
+
//#region recreate files/content/env before any tests
|
|
118
|
+
/**
|
|
119
|
+
* recate original files before any unit/intergration test
|
|
120
|
+
*/
|
|
121
|
+
recreate(testCwd, cwdProj, ProjectClass = Project, onlyIfNotExists = false) {
|
|
122
|
+
// recreat whole structure
|
|
123
|
+
const hashDir = path.join(testCwd, this.json.timeHash);
|
|
124
|
+
if (onlyIfNotExists && Helpers__NS__exists(hashDir)) {
|
|
125
|
+
return;
|
|
126
|
+
}
|
|
127
|
+
Helpers__NS__removeFolderIfExists(hashDir);
|
|
128
|
+
Helpers__NS__mkdirp(hashDir);
|
|
129
|
+
const firstToFind = this.json.projects[this.json.firstProjectBasename].baseStructureHash;
|
|
130
|
+
const allBaseStructures = BaseProjectStructure.allBaseStructures(cwdProj);
|
|
131
|
+
const baseStructure = allBaseStructures.find(p => p.baseStructureHash === firstToFind);
|
|
132
|
+
if (!baseStructure) {
|
|
133
|
+
Helpers__NS__error(`[node-cli-test][regenerate] base structure was not generated for ${firstToFind}`, false, true);
|
|
134
|
+
}
|
|
135
|
+
baseStructure.copyto(hashDir);
|
|
136
|
+
___NS__keys(this.json.projects)
|
|
137
|
+
.filter(key => key !== this.json.firstProjectBasename)
|
|
138
|
+
.map(key => {
|
|
139
|
+
const baseStructureHashChild = this.json.projects[key].baseStructureHash;
|
|
140
|
+
const childBaseStruct = allBaseStructures.find(p => p.baseStructureHash === baseStructureHashChild);
|
|
141
|
+
if (childBaseStruct) {
|
|
142
|
+
childBaseStruct.copyto(path.join(hashDir, path.dirname(key)), path.basename(key));
|
|
143
|
+
}
|
|
144
|
+
});
|
|
145
|
+
this.readonlyMetaJson.orgRelativePathes.forEach((f, i) => {
|
|
146
|
+
const fileToWritePath = path.join(hashDir, f);
|
|
147
|
+
Helpers__NS__writeFile(fileToWritePath, this.fileContentByIndex(i));
|
|
148
|
+
});
|
|
149
|
+
const proj = ProjectClass.ins.From(path.join(hashDir, this.readonlyMetaJson.firstProjectBasename));
|
|
150
|
+
const linksToLInk = []; // proj?.forEmptyStructure().filter(f => !!f.relativeLinkFrom) || [];
|
|
151
|
+
linksToLInk.forEach(l => {
|
|
152
|
+
const source = path.resolve(path.join(proj.location, l.relativeLinkFrom));
|
|
153
|
+
if (Helpers__NS__exists(source)) {
|
|
154
|
+
const dest = path.resolve(path.join(proj.location, l.relativePath));
|
|
155
|
+
Helpers__NS__createSymLink(source, dest);
|
|
156
|
+
}
|
|
157
|
+
else {
|
|
158
|
+
Helpers__NS__log(`[cli-tester][recreate-env] not exist ${source}`);
|
|
159
|
+
}
|
|
160
|
+
});
|
|
161
|
+
}
|
|
160
162
|
}
|
|
163
|
+
//#region create
|
|
161
164
|
async function create(json5string, fileContents, testContent) {
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
const
|
|
175
|
-
|
|
165
|
+
const metadataJSON = Helpers__NS__parse(json5string, true);
|
|
166
|
+
// Helpers__NS__log(`metadataJSON.orgFileBasename: ${metadataJSON.orgFileBasename}`)
|
|
167
|
+
if (!testContent) {
|
|
168
|
+
const projPath = ___NS__maxBy(___NS__keys(metadataJSON.projects).map(projRelPath => {
|
|
169
|
+
return { path: projRelPath, length: projRelPath.length };
|
|
170
|
+
}), c => c.length)?.path || '';
|
|
171
|
+
let TestTemplatesClass = CLASS.getBy('TestTemplates');
|
|
172
|
+
if (!TestTemplatesClass) {
|
|
173
|
+
TestTemplatesClass = await (await import('./spec-templates.backend')).TestTemplates;
|
|
174
|
+
}
|
|
175
|
+
testContent = TestTemplatesClass.testPart(metadataJSON.orgRelativePathes, projPath, metadataJSON.timeHash);
|
|
176
|
+
}
|
|
177
|
+
const filesContestString = fileContents.map((fileContent, i) => {
|
|
178
|
+
const ext = path.extname(metadataJSON.orgFileBasenames[i]).replace(/^\./, '');
|
|
179
|
+
return `\`\`\`${ext} ${MetaMd.FILE_CONTENT_PART}
|
|
176
180
|
${fileContent}
|
|
177
181
|
\`\`\``;
|
|
178
|
-
|
|
179
|
-
|
|
182
|
+
}).join('\n\n');
|
|
183
|
+
return `
|
|
180
184
|
\`\`\`ts ${MetaMd.TEST_PART}
|
|
181
185
|
${testContent}
|
|
182
186
|
\`\`\`
|
|
@@ -186,51 +190,54 @@ ${json5string}
|
|
|
186
190
|
\`\`\`
|
|
187
191
|
|
|
188
192
|
${filesContestString}
|
|
189
|
-
`.split(
|
|
190
|
-
|
|
191
|
-
|
|
193
|
+
`.split('\n').map(l => {
|
|
194
|
+
return l.trim().startsWith('\`\`\`') ? l.trimLeft() : l;
|
|
195
|
+
}).join('\n').trim() + '\n';
|
|
192
196
|
}
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
197
|
+
//#endregion
|
|
198
|
+
//#region extract data parts from content md file
|
|
199
|
+
export function extract(content, PARTS_TO_FIND) {
|
|
200
|
+
if (!content) {
|
|
201
|
+
return;
|
|
202
|
+
}
|
|
203
|
+
const parts = [];
|
|
204
|
+
let lines = [];
|
|
205
|
+
const allLines = content.split('\n');
|
|
206
|
+
let pushingActive = false;
|
|
207
|
+
for (let index = 0; index < allLines.length; index++) {
|
|
208
|
+
const orgLine = (allLines[index] || '');
|
|
209
|
+
const line = orgLine.trim();
|
|
210
|
+
if (pushingActive) {
|
|
211
|
+
if (line.startsWith('\`\`\`')) {
|
|
212
|
+
parts.push(lines.join('\n'));
|
|
213
|
+
lines = [];
|
|
214
|
+
}
|
|
215
|
+
else {
|
|
216
|
+
lines.push(orgLine);
|
|
217
|
+
}
|
|
218
|
+
}
|
|
219
|
+
if (line.startsWith('\`\`\`') && (line.search(PARTS_TO_FIND) !== -1)) {
|
|
220
|
+
pushingActive = true;
|
|
221
|
+
}
|
|
222
|
+
}
|
|
223
|
+
return parts.filter(f => !!f.trim());
|
|
217
224
|
}
|
|
225
|
+
//#endregion
|
|
226
|
+
//#region resolve founded projects
|
|
218
227
|
function resolveFoundedProject(originalAnyTypeFiles, editorCwd, foundProjectFn) {
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
228
|
+
let foundedProjectsInPath = [];
|
|
229
|
+
for (let index = 0; index < originalAnyTypeFiles.length; index++) {
|
|
230
|
+
const fileAbsPath = originalAnyTypeFiles[index];
|
|
231
|
+
foundedProjectsInPath = [
|
|
232
|
+
...foundedProjectsInPath,
|
|
233
|
+
...Project.ins.allProjectFrom(fileAbsPath, editorCwd)
|
|
234
|
+
];
|
|
235
|
+
if (foundProjectFn) {
|
|
236
|
+
foundedProjectsInPath = foundProjectFn(Utils__NS__uniqArray(foundedProjectsInPath, 'location'));
|
|
237
|
+
}
|
|
238
|
+
}
|
|
239
|
+
foundedProjectsInPath = Utils__NS__uniqArray(foundedProjectsInPath, 'location');
|
|
240
|
+
return foundedProjectsInPath;
|
|
232
241
|
}
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
extract
|
|
236
|
-
};
|
|
242
|
+
//#endregion
|
|
243
|
+
//#endregion
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
//@ts-nocheck
|
|
2
|
+
export * from './migrations_index._auto-generated_';
|