incremental-compiler 19.0.24 → 19.0.27
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/client/package.json +1 -1
- package/lib/build-info._auto-generated_.d.ts +1 -1
- package/lib/build-info._auto-generated_.js +1 -1
- package/package.json +1 -6
- package/tmp-environment.json +4 -8
- package/websql/package.json +1 -1
- package/lib/base-client-compiler.backend.d.ts +0 -56
- package/lib/base-client-compiler.backend.js +0 -325
- package/lib/base-client-compiler.backend.js.map +0 -1
- package/lib/change-of-file.backend.d.ts +0 -8
- package/lib/change-of-file.backend.js +0 -25
- package/lib/change-of-file.backend.js.map +0 -1
- package/lib/compiler-manager.backend.d.ts +0 -16
- package/lib/compiler-manager.backend.js +0 -213
- package/lib/compiler-manager.backend.js.map +0 -1
- package/lib/decorators.backend.d.ts +0 -5
- package/lib/decorators.backend.js +0 -56
- package/lib/decorators.backend.js.map +0 -1
- package/lib/helpers.backend.d.ts +0 -3
- package/lib/helpers.backend.js +0 -31
- package/lib/helpers.backend.js.map +0 -1
- package/package.json_devDependencies.json +0 -216
- package/package.json_tnp.json5 +0 -58
package/browser/package.json
CHANGED
package/client/package.json
CHANGED
@@ -4,6 +4,6 @@ exports.CURRENT_PACKAGE_VERSION = exports.PROJECT_NPM_NAME = exports.BUILD_FRAME
|
|
4
4
|
// THIS FILE IS GENERATED - DO NOT MODIFY
|
5
5
|
exports.BUILD_FRAMEWORK_CLI_NAME = 'tnp';
|
6
6
|
exports.PROJECT_NPM_NAME = 'incremental-compiler';
|
7
|
-
exports.CURRENT_PACKAGE_VERSION = '19.0.
|
7
|
+
exports.CURRENT_PACKAGE_VERSION = '19.0.27';
|
8
8
|
// THIS FILE IS GENERATED - DO NOT MODIFY
|
9
9
|
//# sourceMappingURL=build-info._auto-generated_.js.map
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "incremental-compiler",
|
3
|
-
"version": "19.0.
|
3
|
+
"version": "19.0.27",
|
4
4
|
"scripts": {
|
5
5
|
"taon init": "taon init",
|
6
6
|
"taon start": "taon start",
|
@@ -36,10 +36,5 @@
|
|
36
36
|
},
|
37
37
|
"main": "dist/app.electron.js",
|
38
38
|
"bin": {},
|
39
|
-
"exports": {
|
40
|
-
".": {
|
41
|
-
"style": "./scss/index.scss"
|
42
|
-
}
|
43
|
-
},
|
44
39
|
"peerDependencies": {}
|
45
40
|
}
|
package/tmp-environment.json
CHANGED
@@ -8,11 +8,7 @@
|
|
8
8
|
"container": {
|
9
9
|
"only": []
|
10
10
|
},
|
11
|
-
"ports": {
|
12
|
-
"ngNormalAppPort": 4223,
|
13
|
-
"ngWebsqlAppPort": 4224,
|
14
|
-
"nodeBeAppPort": 4109
|
15
|
-
},
|
11
|
+
"ports": {},
|
16
12
|
"init": {},
|
17
13
|
"build": {
|
18
14
|
"pwa": {},
|
@@ -30,12 +26,12 @@
|
|
30
26
|
"releaseType": "manual",
|
31
27
|
"targetArtifact": "npm-lib-and-cli-tool",
|
32
28
|
"envName": "__",
|
33
|
-
"resolvedNewVersion": "19.0.
|
29
|
+
"resolvedNewVersion": "19.0.27"
|
34
30
|
},
|
35
31
|
"copyToManager": {},
|
36
32
|
"buildInfo": {
|
37
|
-
"date": "2025-05-
|
38
|
-
"hash": "
|
33
|
+
"date": "2025-05-29T20:31:07.000Z",
|
34
|
+
"hash": "915f77bba130f64a2a71ff16547277769fdb73d3"
|
39
35
|
},
|
40
36
|
"currentProjectName": "incremental-compiler",
|
41
37
|
"currentProjectType": "isomorphic-lib",
|
package/websql/package.json
CHANGED
@@ -1,56 +0,0 @@
|
|
1
|
-
import { ChangeOfFile } from './change-of-file.backend';
|
2
|
-
import { Models } from './models';
|
3
|
-
import { CoreModels } from 'tnp-core';
|
4
|
-
export declare class BaseClientCompiler<INITAL_PARAMS = any> implements Models.BaseClientCompilerOptions {
|
5
|
-
readonly followSymlinks: boolean;
|
6
|
-
readonly subscribeOnlyFor: CoreModels.FileExtension[];
|
7
|
-
readonly executeOutsideScenario: boolean;
|
8
|
-
readonly taskName: string;
|
9
|
-
ignoreFolderPatter?: string[];
|
10
|
-
readonly notifyOnFileUnlink: boolean;
|
11
|
-
compilationWrapper: (fn: () => void, taskName?: string, executionType?: "Compilation of" | "Code execution of" | "Event:") => Promise<void>;
|
12
|
-
private pathResolve;
|
13
|
-
private initedWithOptions;
|
14
|
-
private __folderPath;
|
15
|
-
lastAsyncFiles: string[];
|
16
|
-
private _folderPathContentCheck;
|
17
|
-
get isInited(): boolean;
|
18
|
-
get folderPathContentCheck(): string[];
|
19
|
-
private set folderPathContentCheck(value);
|
20
|
-
set folderPath(v: string[]);
|
21
|
-
get folderPath(): string[];
|
22
|
-
constructor(options?: Models.BaseClientCompilerOptions);
|
23
|
-
/**
|
24
|
-
* manually init options (when no passing object to constructor super() )
|
25
|
-
*/
|
26
|
-
protected initOptions(options?: Models.BaseClientCompilerOptions): void;
|
27
|
-
protected onlySingleRun: boolean;
|
28
|
-
/**
|
29
|
-
* do not override this
|
30
|
-
*/
|
31
|
-
runTask(options?: {
|
32
|
-
watch: boolean;
|
33
|
-
} & Models.StartAndWatchOptions<INITAL_PARAMS>): Promise<BaseClientCompiler<INITAL_PARAMS>>;
|
34
|
-
/**
|
35
|
-
* @deprecated use runTask instead
|
36
|
-
* Do not override this
|
37
|
-
*/
|
38
|
-
start(options?: Models.StartOptions<INITAL_PARAMS>): Promise<BaseClientCompiler<INITAL_PARAMS>>;
|
39
|
-
/**
|
40
|
-
* @deprecated use runTask instead
|
41
|
-
* Do not override this
|
42
|
-
*/
|
43
|
-
startAndWatch(options?: Models.StartAndWatchOptions<INITAL_PARAMS>): Promise<BaseClientCompiler<INITAL_PARAMS>>;
|
44
|
-
/**
|
45
|
-
*
|
46
|
-
* @param absolteFilesPathes for each watched file
|
47
|
-
* @returns
|
48
|
-
*/
|
49
|
-
syncAction(absolteFilesPathes?: string[], initalParams?: INITAL_PARAMS): Promise<void>;
|
50
|
-
preAsyncAction(initalParams?: INITAL_PARAMS): Promise<void>;
|
51
|
-
asyncAction(asyncEvents: ChangeOfFile, initalParams?: INITAL_PARAMS): Promise<void>;
|
52
|
-
private _init;
|
53
|
-
private fixTaskName;
|
54
|
-
filesToWatch(): string[];
|
55
|
-
private mapForWatching;
|
56
|
-
}
|
@@ -1,325 +0,0 @@
|
|
1
|
-
"use strict";
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.BaseClientCompiler = void 0;
|
4
|
-
var tslib_1 = require("tslib");
|
5
|
-
//#region imports
|
6
|
-
var tnp_core_1 = require("tnp-core");
|
7
|
-
var compiler_manager_backend_1 = require("./compiler-manager.backend");
|
8
|
-
var tnp_core_2 = require("tnp-core");
|
9
|
-
var tnp_core_3 = require("tnp-core");
|
10
|
-
//#endregion
|
11
|
-
var BaseClientCompiler = /** @class */ (function () {
|
12
|
-
//#endregion
|
13
|
-
//#endregion
|
14
|
-
//#region constructor
|
15
|
-
function BaseClientCompiler(options) {
|
16
|
-
this.subscribeOnlyFor = [];
|
17
|
-
this.compilationWrapper = tnp_core_2.Helpers.compilationWrapper;
|
18
|
-
this.pathResolve = false;
|
19
|
-
this.initedWithOptions = false;
|
20
|
-
this.__folderPath = [];
|
21
|
-
this.lastAsyncFiles = [];
|
22
|
-
this._folderPathContentCheck = [];
|
23
|
-
//#endregion
|
24
|
-
this.onlySingleRun = true;
|
25
|
-
if (tnp_core_1._.isUndefined(options)) {
|
26
|
-
this.initedWithOptions = false;
|
27
|
-
tnp_core_2.Helpers.log('[incremental-compiler] Compiler class instace without init options');
|
28
|
-
}
|
29
|
-
else {
|
30
|
-
this.initedWithOptions = true;
|
31
|
-
this._init(options);
|
32
|
-
}
|
33
|
-
}
|
34
|
-
Object.defineProperty(BaseClientCompiler.prototype, "isInited", {
|
35
|
-
//#endregion
|
36
|
-
//#region getters & setteres
|
37
|
-
//#region getters & setteres / is inited
|
38
|
-
get: function () {
|
39
|
-
return this.initedWithOptions;
|
40
|
-
},
|
41
|
-
enumerable: false,
|
42
|
-
configurable: true
|
43
|
-
});
|
44
|
-
Object.defineProperty(BaseClientCompiler.prototype, "folderPathContentCheck", {
|
45
|
-
//#endregion
|
46
|
-
//#region getters & setteres / folder path content check
|
47
|
-
get: function () {
|
48
|
-
return this._folderPathContentCheck;
|
49
|
-
},
|
50
|
-
set: function (v) {
|
51
|
-
this._folderPathContentCheck = v;
|
52
|
-
},
|
53
|
-
enumerable: false,
|
54
|
-
configurable: true
|
55
|
-
});
|
56
|
-
Object.defineProperty(BaseClientCompiler.prototype, "folderPath", {
|
57
|
-
get: function () {
|
58
|
-
var _this = this;
|
59
|
-
if (!this.pathResolve) {
|
60
|
-
this.pathResolve = true;
|
61
|
-
this.__folderPath
|
62
|
-
.map(function (p) {
|
63
|
-
if (tnp_core_1.fse.existsSync(p)) {
|
64
|
-
return (0, tnp_core_1.crossPlatformPath)(tnp_core_1.path.resolve(p));
|
65
|
-
}
|
66
|
-
else {
|
67
|
-
tnp_core_2.Helpers.warn("[BaseClientCompiler] Task \"".concat(_this.taskName, "\" folderPath doesn't not exist ").concat(_this.folderPath));
|
68
|
-
return void 0;
|
69
|
-
}
|
70
|
-
})
|
71
|
-
.filter(function (f) { return !!f; });
|
72
|
-
}
|
73
|
-
return this.__folderPath;
|
74
|
-
},
|
75
|
-
//#endregion
|
76
|
-
//#region getters & setteres / folder path
|
77
|
-
set: function (v) {
|
78
|
-
if (tnp_core_1._.isString(v)) {
|
79
|
-
v = [v];
|
80
|
-
}
|
81
|
-
this.__folderPath = v;
|
82
|
-
},
|
83
|
-
enumerable: false,
|
84
|
-
configurable: true
|
85
|
-
});
|
86
|
-
//#endregion
|
87
|
-
//#region api methods
|
88
|
-
//#region api methods / init options
|
89
|
-
/**
|
90
|
-
* manually init options (when no passing object to constructor super() )
|
91
|
-
*/
|
92
|
-
BaseClientCompiler.prototype.initOptions = function (options) {
|
93
|
-
if (this.initedWithOptions === true) {
|
94
|
-
tnp_core_2.Helpers.warn("[incremental-compiler] You can't reinit instance class again..." +
|
95
|
-
" (after reiniting in constructor super(....))", true);
|
96
|
-
}
|
97
|
-
if (!options) {
|
98
|
-
tnp_core_2.Helpers.error("[incremental-compiler] Please init instance with options config", false, true);
|
99
|
-
}
|
100
|
-
this.initedWithOptions = true;
|
101
|
-
this._init(options);
|
102
|
-
};
|
103
|
-
//#region api methods / start
|
104
|
-
/**
|
105
|
-
* do not override this
|
106
|
-
*/
|
107
|
-
BaseClientCompiler.prototype.runTask = function (options) {
|
108
|
-
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
109
|
-
return tslib_1.__generator(this, function (_a) {
|
110
|
-
switch (_a.label) {
|
111
|
-
case 0:
|
112
|
-
if (!(options === null || options === void 0 ? void 0 : options.watch)) return [3 /*break*/, 2];
|
113
|
-
return [4 /*yield*/, this.startAndWatch(options)];
|
114
|
-
case 1:
|
115
|
-
_a.sent();
|
116
|
-
return [3 /*break*/, 4];
|
117
|
-
case 2: return [4 /*yield*/, this.start(options)];
|
118
|
-
case 3:
|
119
|
-
_a.sent();
|
120
|
-
_a.label = 4;
|
121
|
-
case 4: return [2 /*return*/, this];
|
122
|
-
}
|
123
|
-
});
|
124
|
-
});
|
125
|
-
};
|
126
|
-
//#region api methods / start
|
127
|
-
/**
|
128
|
-
* @deprecated use runTask instead
|
129
|
-
* Do not override this
|
130
|
-
*/
|
131
|
-
BaseClientCompiler.prototype.start = function (options) {
|
132
|
-
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
133
|
-
var _a, taskName, afterInitCallBack, initalParams;
|
134
|
-
var _this = this;
|
135
|
-
return tslib_1.__generator(this, function (_b) {
|
136
|
-
switch (_b.label) {
|
137
|
-
case 0:
|
138
|
-
_a = options || {}, taskName = _a.taskName, afterInitCallBack = _a.afterInitCallBack, initalParams = _a.initalParams;
|
139
|
-
compiler_manager_backend_1.CompilerManager.Instance.addClient(this);
|
140
|
-
if (!this.initedWithOptions) {
|
141
|
-
tnp_core_2.Helpers.error("[BaseClientCompiler] Please init client class intance with options", false, true);
|
142
|
-
}
|
143
|
-
taskName = this.fixTaskName(taskName);
|
144
|
-
// @ts-ignore
|
145
|
-
this.taskName = taskName;
|
146
|
-
return [4 /*yield*/, this.compilationWrapper(function () { return tslib_1.__awaiter(_this, void 0, void 0, function () {
|
147
|
-
return tslib_1.__generator(this, function (_a) {
|
148
|
-
switch (_a.label) {
|
149
|
-
case 0: return [4 /*yield*/, compiler_manager_backend_1.CompilerManager.Instance.syncInit(this, initalParams)];
|
150
|
-
case 1:
|
151
|
-
_a.sent();
|
152
|
-
return [2 /*return*/];
|
153
|
-
}
|
154
|
-
});
|
155
|
-
}); }, "".concat(tnp_core_3.CLI.chalk.green('sync action'), " for ").concat(taskName), 'Event:')];
|
156
|
-
case 1:
|
157
|
-
_b.sent();
|
158
|
-
if (!tnp_core_1._.isFunction(afterInitCallBack)) return [3 /*break*/, 3];
|
159
|
-
return [4 /*yield*/, tnp_core_2.Helpers.runSyncOrAsync({
|
160
|
-
functionFn: afterInitCallBack,
|
161
|
-
arrayOfParams: [initalParams],
|
162
|
-
})];
|
163
|
-
case 2:
|
164
|
-
_b.sent();
|
165
|
-
_b.label = 3;
|
166
|
-
case 3: return [2 /*return*/, this];
|
167
|
-
}
|
168
|
-
});
|
169
|
-
});
|
170
|
-
};
|
171
|
-
//#endregion
|
172
|
-
//#region api methods / start and watch
|
173
|
-
/**
|
174
|
-
* @deprecated use runTask instead
|
175
|
-
* Do not override this
|
176
|
-
*/
|
177
|
-
BaseClientCompiler.prototype.startAndWatch = function (options) {
|
178
|
-
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
179
|
-
var _a, taskName, watchOnly, initalParams;
|
180
|
-
var _this = this;
|
181
|
-
return tslib_1.__generator(this, function (_b) {
|
182
|
-
switch (_b.label) {
|
183
|
-
case 0:
|
184
|
-
_a = options || {}, taskName = _a.taskName, watchOnly = _a.watchOnly, initalParams = _a.initalParams;
|
185
|
-
this.onlySingleRun = false;
|
186
|
-
if (!this.initedWithOptions) {
|
187
|
-
tnp_core_2.Helpers.error("[BaseClientCompiler] Please init client class intance with options", false, true);
|
188
|
-
}
|
189
|
-
taskName = this.fixTaskName(taskName);
|
190
|
-
// @ts-ignore
|
191
|
-
this.taskName = taskName;
|
192
|
-
if (!(this.folderPath.length > 0)) return [3 /*break*/, 7];
|
193
|
-
if (!watchOnly) return [3 /*break*/, 1];
|
194
|
-
console.log(tnp_core_3.CLI.chalk.gray("[incremental-compiler] Watch mode only for \"".concat(taskName, "\"")));
|
195
|
-
return [3 /*break*/, 3];
|
196
|
-
case 1: return [4 /*yield*/, this.start(options)];
|
197
|
-
case 2:
|
198
|
-
_b.sent();
|
199
|
-
_b.label = 3;
|
200
|
-
case 3:
|
201
|
-
if (!tnp_core_1._.isFunction(this.preAsyncAction)) return [3 /*break*/, 5];
|
202
|
-
return [4 /*yield*/, this.compilationWrapper(function () { return tslib_1.__awaiter(_this, void 0, void 0, function () {
|
203
|
-
return tslib_1.__generator(this, function (_a) {
|
204
|
-
switch (_a.label) {
|
205
|
-
case 0: return [4 /*yield*/, this.preAsyncAction((initalParams || {}))];
|
206
|
-
case 1:
|
207
|
-
_a.sent();
|
208
|
-
return [2 /*return*/];
|
209
|
-
}
|
210
|
-
});
|
211
|
-
}); }, "".concat(tnp_core_3.CLI.chalk.green('pre-async action'), " for ").concat(taskName), 'Event:')];
|
212
|
-
case 4:
|
213
|
-
_b.sent();
|
214
|
-
_b.label = 5;
|
215
|
-
case 5: return [4 /*yield*/, compiler_manager_backend_1.CompilerManager.Instance.asyncInit(this, initalParams || {})];
|
216
|
-
case 6:
|
217
|
-
_b.sent();
|
218
|
-
return [3 /*break*/, 9];
|
219
|
-
case 7:
|
220
|
-
tnp_core_2.Helpers.log("No action for task: ".concat(taskName, ".. starting task"));
|
221
|
-
return [4 /*yield*/, this.start(options)];
|
222
|
-
case 8:
|
223
|
-
_b.sent();
|
224
|
-
_b.label = 9;
|
225
|
-
case 9: return [2 /*return*/, this];
|
226
|
-
}
|
227
|
-
});
|
228
|
-
});
|
229
|
-
};
|
230
|
-
//#endregion
|
231
|
-
//#region api methods / sync action
|
232
|
-
/**
|
233
|
-
*
|
234
|
-
* @param absolteFilesPathes for each watched file
|
235
|
-
* @returns
|
236
|
-
*/
|
237
|
-
BaseClientCompiler.prototype.syncAction = function (absolteFilesPathes, initalParams) {
|
238
|
-
return void 0;
|
239
|
-
};
|
240
|
-
//#endregion
|
241
|
-
//#region api methods / pre async action
|
242
|
-
BaseClientCompiler.prototype.preAsyncAction = function (initalParams) {
|
243
|
-
return tslib_1.__awaiter(this, void 0, void 0, function () { return tslib_1.__generator(this, function (_a) {
|
244
|
-
return [2 /*return*/];
|
245
|
-
}); });
|
246
|
-
};
|
247
|
-
//#endregion
|
248
|
-
//#region api methods / async action
|
249
|
-
BaseClientCompiler.prototype.asyncAction = function (asyncEvents, initalParams) {
|
250
|
-
return void 0;
|
251
|
-
};
|
252
|
-
//#endregion
|
253
|
-
//#endregion
|
254
|
-
//#region private methods
|
255
|
-
//#region private methods / _init
|
256
|
-
BaseClientCompiler.prototype._init = function (options) {
|
257
|
-
if (!tnp_core_1._.isArray(options.subscribeOnlyFor)) {
|
258
|
-
options.subscribeOnlyFor = [];
|
259
|
-
}
|
260
|
-
if (tnp_core_1._.isUndefined(options.folderPath)) {
|
261
|
-
options.folderPath = [];
|
262
|
-
}
|
263
|
-
if (tnp_core_1._.isUndefined(options.folderPathContentCheck)) {
|
264
|
-
options.folderPathContentCheck = [];
|
265
|
-
}
|
266
|
-
if (tnp_core_1._.isUndefined(options.ignoreFolderPatter)) {
|
267
|
-
options.ignoreFolderPatter = [];
|
268
|
-
}
|
269
|
-
if (tnp_core_1._.isString(options.folderPath)) {
|
270
|
-
options.folderPath = [options.folderPath];
|
271
|
-
}
|
272
|
-
if (tnp_core_1._.isString(options.folderPathContentCheck)) {
|
273
|
-
options.folderPathContentCheck = [options.folderPathContentCheck];
|
274
|
-
}
|
275
|
-
if (!tnp_core_1._.isString(options.folderPath) && !tnp_core_1._.isArray(options.folderPath)) {
|
276
|
-
tnp_core_2.Helpers.error("Folder path shoudl be string or array", false, true);
|
277
|
-
}
|
278
|
-
if (!tnp_core_1._.isString(options.folderPathContentCheck) &&
|
279
|
-
!tnp_core_1._.isArray(options.folderPathContentCheck)) {
|
280
|
-
tnp_core_2.Helpers.error("Folder path shoudl be string or array", false, true);
|
281
|
-
}
|
282
|
-
if (tnp_core_1._.isUndefined(options.followSymlinks)) {
|
283
|
-
options.followSymlinks = false;
|
284
|
-
}
|
285
|
-
if (tnp_core_1._.isUndefined(options.notifyOnFileUnlink)) {
|
286
|
-
options.notifyOnFileUnlink = false;
|
287
|
-
}
|
288
|
-
// console.log('ASSIGNE', options)
|
289
|
-
Object.assign(this, options);
|
290
|
-
};
|
291
|
-
//#endregion
|
292
|
-
//#region private methods / fix task name
|
293
|
-
BaseClientCompiler.prototype.fixTaskName = function (taskName) {
|
294
|
-
if (!tnp_core_1._.isString(taskName)) {
|
295
|
-
taskName = "task \"".concat(this.taskName, "\"");
|
296
|
-
}
|
297
|
-
return taskName;
|
298
|
-
};
|
299
|
-
//#endregion
|
300
|
-
BaseClientCompiler.prototype.filesToWatch = function () {
|
301
|
-
var _this = this;
|
302
|
-
var folders = [];
|
303
|
-
// this.clients.forEach(c => {
|
304
|
-
[this].forEach(function (c) {
|
305
|
-
// console.log("c.folderPath", c.folderPath)
|
306
|
-
c.folderPath.forEach(function (folderPath) {
|
307
|
-
// console.log(`fp`, fp)
|
308
|
-
if (tnp_core_1._.isString(folderPath) && !folders.includes(folderPath)) {
|
309
|
-
var mapped = _this.mapForWatching(folderPath);
|
310
|
-
folders.push.apply(folders, tslib_1.__spreadArray([], tslib_1.__read(mapped), false));
|
311
|
-
}
|
312
|
-
});
|
313
|
-
});
|
314
|
-
return tnp_core_1._.cloneDeep(folders);
|
315
|
-
};
|
316
|
-
BaseClientCompiler.prototype.mapForWatching = function (c) {
|
317
|
-
if (tnp_core_1.fse.existsSync(c) && tnp_core_1.fse.lstatSync(c).isDirectory()) {
|
318
|
-
return [c, "".concat(c, "/**/*.*")];
|
319
|
-
}
|
320
|
-
return [c];
|
321
|
-
};
|
322
|
-
return BaseClientCompiler;
|
323
|
-
}());
|
324
|
-
exports.BaseClientCompiler = BaseClientCompiler;
|
325
|
-
//# sourceMappingURL=base-client-compiler.backend.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"base-client-compiler.backend.js","sourceRoot":"","sources":["c:/Users/darek/projects/npm/taon-dev/incremental-compiler/src/lib/base-client-compiler.backend.ts"],"names":[],"mappings":";;;;AAAA,iBAAiB;AACjB,qCAA2D;AAE3D,uEAA6D;AAE7D,qCAAmC;AACnC,qCAA+B;AAE/B,YAAY;AAEZ;IA6DE,YAAY;IAEZ,YAAY;IAEZ,qBAAqB;IACrB,4BAAY,OAA0C;QA7DtC,qBAAgB,GAA+B,EAAE,CAAC;QAK3D,uBAAkB,GAAG,kBAAO,CAAC,kBAAkB,CAAC;QAC/C,gBAAW,GAAY,KAAK,CAAC;QAC7B,sBAAiB,GAAG,KAAK,CAAC;QAC1B,iBAAY,GAAa,EAAE,CAAC;QAC7B,mBAAc,GAAa,EAAE,CAAC;QAC7B,4BAAuB,GAAa,EAAE,CAAC;QAwF/C,YAAY;QAEF,kBAAa,GAAG,IAAI,CAAC;QAtC7B,IAAI,YAAC,CAAC,WAAW,CAAC,OAAO,CAAC,EAAE,CAAC;YAC3B,IAAI,CAAC,iBAAiB,GAAG,KAAK,CAAC;YAC/B,kBAAO,CAAC,GAAG,CACT,oEAAoE,CACrE,CAAC;QACJ,CAAC;aAAM,CAAC;YACN,IAAI,CAAC,iBAAiB,GAAG,IAAI,CAAC;YAC9B,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;QACtB,CAAC;IACH,CAAC;IAtDD,sBAAI,wCAAQ;QALZ,YAAY;QAEZ,4BAA4B;QAE5B,wCAAwC;aACxC;YACE,OAAO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AAC,CAAC,CAAC,CAAC,WAAW,EAAE,EAAE,CAAC;YACxD,OAAO,CAAC,CAAC,EAAE,UAAG,CAAC,YAAS,CAAC,CAAC;QAC5B,CAAC;QACD,OAAO,CAAC,CAAC,CAAC,CAAC;IACb,CAAC;IAGH,yBAAC;AAAD,CAAC,AA3TD,IA2TC;AA3TY,gDAAkB"}
|
@@ -1,8 +0,0 @@
|
|
1
|
-
import { CoreModels } from 'tnp-core';
|
2
|
-
export declare class ChangeOfFile {
|
3
|
-
fileAbsolutePath: string;
|
4
|
-
readonly eventName: 'add' | 'change' | 'unlink' | 'unlinkDir';
|
5
|
-
readonly datetime: Date;
|
6
|
-
constructor(fileAbsolutePath?: string, eventName?: 'add' | 'change' | 'unlink' | 'unlinkDir');
|
7
|
-
get fileExt(): CoreModels.FileExtension;
|
8
|
-
}
|
@@ -1,25 +0,0 @@
|
|
1
|
-
"use strict";
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.ChangeOfFile = void 0;
|
4
|
-
//#region imports
|
5
|
-
var tnp_core_1 = require("tnp-core");
|
6
|
-
//#endregion
|
7
|
-
var ChangeOfFile = /** @class */ (function () {
|
8
|
-
function ChangeOfFile(fileAbsolutePath, eventName) {
|
9
|
-
if (fileAbsolutePath === void 0) { fileAbsolutePath = void 0; }
|
10
|
-
if (eventName === void 0) { eventName = (void 0); }
|
11
|
-
this.fileAbsolutePath = fileAbsolutePath;
|
12
|
-
this.eventName = eventName;
|
13
|
-
this.datetime = new Date();
|
14
|
-
}
|
15
|
-
Object.defineProperty(ChangeOfFile.prototype, "fileExt", {
|
16
|
-
get: function () {
|
17
|
-
return tnp_core_1.path.extname(this.fileAbsolutePath).replace('.', '');
|
18
|
-
},
|
19
|
-
enumerable: false,
|
20
|
-
configurable: true
|
21
|
-
});
|
22
|
-
return ChangeOfFile;
|
23
|
-
}());
|
24
|
-
exports.ChangeOfFile = ChangeOfFile;
|
25
|
-
//# sourceMappingURL=change-of-file.backend.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"change-of-file.backend.js","sourceRoot":"","sources":["c:/Users/darek/projects/npm/taon-dev/incremental-compiler/src/lib/change-of-file.backend.ts"],"names":[],"mappings":";;;AAAA,iBAAiB;AACjB,qCAAmC;AAGnC,YAAY;AAEZ;IAIE,sBACS,gBAAiC,EACxB,SAA+D;QADxE,iCAAA,EAAA,wBAAgC,CAAC;QACxB,0BAAA,EAAA,aAAwD,KAAK,CAAC,CAAC;QADxE,qBAAgB,GAAhB,gBAAgB,CAAiB;QACxB,cAAS,GAAT,SAAS,CAAsD;QAE/E,IAAI,CAAC,QAAQ,GAAG,IAAI,IAAI,EAAE,CAAC;IAC7B,CAAC;IAED,sBAAW,iCAAO;aAAlB;YACE,OAAO,eAAI,CAAC,OAAO,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,CAA6B,CAAC;QAC1F,CAAC;;;OAAA;IAEH,mBAAC;AAAD,CAAC,AAfD,IAeC;AAfY,oCAAY"}
|
@@ -1,16 +0,0 @@
|
|
1
|
-
import { BaseClientCompiler } from './base-client-compiler.backend';
|
2
|
-
export declare class CompilerManager {
|
3
|
-
private static _instance;
|
4
|
-
static get Instance(): CompilerManager;
|
5
|
-
private clients;
|
6
|
-
private asyncEventScenario;
|
7
|
-
private inited;
|
8
|
-
private filesContentCache;
|
9
|
-
private constructor();
|
10
|
-
syncInit(client: BaseClientCompiler<any>, initalParams: any): Promise<void>;
|
11
|
-
asyncInit(client: BaseClientCompiler<any>, initialParams: any): Promise<void>;
|
12
|
-
private actionForAsyncEvent;
|
13
|
-
addClient(client: BaseClientCompiler<any>): void;
|
14
|
-
private preventAlreadyInited;
|
15
|
-
private fileShouldBeChecked;
|
16
|
-
}
|
@@ -1,213 +0,0 @@
|
|
1
|
-
"use strict";
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.CompilerManager = void 0;
|
4
|
-
var tslib_1 = require("tslib");
|
5
|
-
//#region imports
|
6
|
-
//#region @backend
|
7
|
-
var tnp_core_1 = require("tnp-core");
|
8
|
-
//#endregion
|
9
|
-
var tnp_core_2 = require("tnp-core");
|
10
|
-
var tnp_helpers_1 = require("tnp-helpers");
|
11
|
-
var change_of_file_backend_1 = require("./change-of-file.backend");
|
12
|
-
var constants_1 = require("./constants");
|
13
|
-
var incremental_watcher_1 = require("./incremental-watcher");
|
14
|
-
//#region for debugging purpose...
|
15
|
-
// require('colors');
|
16
|
-
// const Diff = require('diff');
|
17
|
-
//#endregion
|
18
|
-
//#endregion
|
19
|
-
var ignoreByDefault = ['**/node_modules/**/*.*', '**/node_modules'];
|
20
|
-
var CompilerManager = /** @class */ (function () {
|
21
|
-
//#endregion
|
22
|
-
//#region constructor
|
23
|
-
function CompilerManager() {
|
24
|
-
//#endregion
|
25
|
-
//#endregion
|
26
|
-
//#region fields & getters
|
27
|
-
this.clients = [];
|
28
|
-
this.inited = false;
|
29
|
-
this.filesContentCache = {};
|
30
|
-
}
|
31
|
-
Object.defineProperty(CompilerManager, "Instance", {
|
32
|
-
get: function () {
|
33
|
-
if (!this._instance) {
|
34
|
-
this._instance = new CompilerManager();
|
35
|
-
}
|
36
|
-
return this._instance;
|
37
|
-
},
|
38
|
-
enumerable: false,
|
39
|
-
configurable: true
|
40
|
-
});
|
41
|
-
//#endregion
|
42
|
-
//#region methods / sync init
|
43
|
-
CompilerManager.prototype.syncInit = function (client, initalParams) {
|
44
|
-
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
45
|
-
var files, index, absFilePath, fileShouldBeCached;
|
46
|
-
return tslib_1.__generator(this, function (_a) {
|
47
|
-
switch (_a.label) {
|
48
|
-
case 0:
|
49
|
-
files = [];
|
50
|
-
if (tnp_core_2._.isArray(client.folderPath) && client.folderPath.length > 0) {
|
51
|
-
files = client.folderPath
|
52
|
-
.reduce(function (folderOrFileA, folderOrFileB) {
|
53
|
-
folderOrFileB = (0, tnp_core_2.crossPlatformPath)(folderOrFileB);
|
54
|
-
var filesFromB = [folderOrFileB];
|
55
|
-
if (tnp_core_1.fse.existsSync(folderOrFileB) &&
|
56
|
-
tnp_core_1.fse.lstatSync(folderOrFileB).isDirectory()) {
|
57
|
-
debugger;
|
58
|
-
var globPath = "".concat(folderOrFileB, "/**/*.*");
|
59
|
-
var ignore = tslib_1.__spreadArray(tslib_1.__spreadArray([], tslib_1.__read(ignoreByDefault), false), tslib_1.__read(client.ignoreFolderPatter), false);
|
60
|
-
// console.log({ ignore });
|
61
|
-
filesFromB = tnp_core_1.fg.sync(globPath, {
|
62
|
-
// ! TODO QUICK_FIX for v18 @LAST
|
63
|
-
// symlinks: client.followSymlinks as any,
|
64
|
-
followSymbolicLinks: client.followSymlinks,
|
65
|
-
ignore: ignore,
|
66
|
-
dot: true,
|
67
|
-
});
|
68
|
-
// console.log({
|
69
|
-
// globPath,
|
70
|
-
// globIgnore,
|
71
|
-
// GENERATEDFILES: filesFromB.length
|
72
|
-
// })
|
73
|
-
}
|
74
|
-
return folderOrFileA.concat(filesFromB);
|
75
|
-
}, [])
|
76
|
-
.filter(function (f) {
|
77
|
-
if (client.subscribeOnlyFor.length > 0) {
|
78
|
-
return client.subscribeOnlyFor.includes(tnp_core_2.path.extname(f).replace('.', ''));
|
79
|
-
}
|
80
|
-
return true;
|
81
|
-
});
|
82
|
-
}
|
83
|
-
// console.log(`Files for client.folderPath: ${client.folderPath} client.followSymlinks: ${client.followSymlinks}`)
|
84
|
-
for (index = 0; index < files.length; index++) {
|
85
|
-
absFilePath = files[index];
|
86
|
-
fileShouldBeCached = this.fileShouldBeChecked(absFilePath, client);
|
87
|
-
if (fileShouldBeCached) {
|
88
|
-
this.filesContentCache[absFilePath] = (tnp_helpers_1.Helpers.readFile(absFilePath) || '').trim();
|
89
|
-
}
|
90
|
-
}
|
91
|
-
return [4 /*yield*/, client.syncAction(files, initalParams)];
|
92
|
-
case 1:
|
93
|
-
_a.sent();
|
94
|
-
return [2 /*return*/];
|
95
|
-
}
|
96
|
-
});
|
97
|
-
});
|
98
|
-
};
|
99
|
-
//#endregion
|
100
|
-
//#region methods / async init
|
101
|
-
CompilerManager.prototype.asyncInit = function (client, initialParams) {
|
102
|
-
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
103
|
-
var watchers, ignored, watcher;
|
104
|
-
var _this = this;
|
105
|
-
return tslib_1.__generator(this, function (_a) {
|
106
|
-
switch (_a.label) {
|
107
|
-
case 0:
|
108
|
-
watchers = [];
|
109
|
-
ignored = tslib_1.__spreadArray(tslib_1.__spreadArray([], tslib_1.__read(ignoreByDefault), false), tslib_1.__read(client.ignoreFolderPatter), false);
|
110
|
-
return [4 /*yield*/, (0, incremental_watcher_1.incrementalWatcher)(client.filesToWatch(), tslib_1.__assign({ name: "[incremental-compiler watcher for ".concat(client.taskName, "]"), ignoreInitial: true, followSymlinks: client.followSymlinks, ignored: ignored }, constants_1.COMPILER_POOLING))];
|
111
|
-
case 1:
|
112
|
-
watcher = (_a.sent()).on('all', function (event, absoluteFilePath) { return tslib_1.__awaiter(_this, void 0, void 0, function () {
|
113
|
-
return tslib_1.__generator(this, function (_a) {
|
114
|
-
switch (_a.label) {
|
115
|
-
case 0:
|
116
|
-
// console.log(`[ic] event ${event}, path: ${absoluteFilePath}`);
|
117
|
-
return [4 /*yield*/, this.actionForAsyncEvent(event, absoluteFilePath, client, initialParams)];
|
118
|
-
case 1:
|
119
|
-
// console.log(`[ic] event ${event}, path: ${absoluteFilePath}`);
|
120
|
-
_a.sent();
|
121
|
-
return [2 /*return*/];
|
122
|
-
}
|
123
|
-
});
|
124
|
-
}); });
|
125
|
-
watchers.push(watcher);
|
126
|
-
return [2 /*return*/];
|
127
|
-
}
|
128
|
-
});
|
129
|
-
});
|
130
|
-
};
|
131
|
-
CompilerManager.prototype.actionForAsyncEvent = function (event, absoluteFilePath, client, initalParams) {
|
132
|
-
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
133
|
-
var proceeedWithAsyncChange, fileShouldBeCached, currentContent, change;
|
134
|
-
return tslib_1.__generator(this, function (_a) {
|
135
|
-
switch (_a.label) {
|
136
|
-
case 0:
|
137
|
-
absoluteFilePath = (0, tnp_core_2.crossPlatformPath)(absoluteFilePath);
|
138
|
-
if (event === 'addDir') {
|
139
|
-
return [2 /*return*/];
|
140
|
-
}
|
141
|
-
if (client.lastAsyncFiles.includes(absoluteFilePath)) {
|
142
|
-
return [2 /*return*/];
|
143
|
-
}
|
144
|
-
else {
|
145
|
-
client.lastAsyncFiles.push(absoluteFilePath);
|
146
|
-
}
|
147
|
-
// console.log(`[ic] final event ${event}, path: ${absoluteFilePath}`, 1);
|
148
|
-
// console.log('this.clients', this.clients.map(c => c.key))
|
149
|
-
if (event === 'unlink' && !client.notifyOnFileUnlink) {
|
150
|
-
return [2 /*return*/];
|
151
|
-
}
|
152
|
-
proceeedWithAsyncChange = true;
|
153
|
-
fileShouldBeCached = this.fileShouldBeChecked(absoluteFilePath, client);
|
154
|
-
if (!(fileShouldBeCached && event === 'change')) return [3 /*break*/, 2];
|
155
|
-
return [4 /*yield*/, tnp_helpers_1.Helpers.tryReadFile(absoluteFilePath)];
|
156
|
-
case 1:
|
157
|
-
currentContent = ((_a.sent()) || '').trim();
|
158
|
-
if (currentContent === this.filesContentCache[absoluteFilePath]) {
|
159
|
-
// console.log('FILE THE SAME ' + absoluteFilePath)
|
160
|
-
proceeedWithAsyncChange = false;
|
161
|
-
}
|
162
|
-
else {
|
163
|
-
this.filesContentCache[absoluteFilePath] = currentContent;
|
164
|
-
}
|
165
|
-
_a.label = 2;
|
166
|
-
case 2:
|
167
|
-
if (!proceeedWithAsyncChange) return [3 /*break*/, 6];
|
168
|
-
change = new change_of_file_backend_1.ChangeOfFile(absoluteFilePath, event);
|
169
|
-
if (!this.asyncEventScenario) return [3 /*break*/, 4];
|
170
|
-
return [4 /*yield*/, this.asyncEventScenario(change)];
|
171
|
-
case 3:
|
172
|
-
_a.sent();
|
173
|
-
_a.label = 4;
|
174
|
-
case 4: return [4 /*yield*/, client.asyncAction(change, initalParams)];
|
175
|
-
case 5:
|
176
|
-
_a.sent();
|
177
|
-
_a.label = 6;
|
178
|
-
case 6:
|
179
|
-
client.lastAsyncFiles = client.lastAsyncFiles.filter(function (ef) { return ef !== absoluteFilePath; });
|
180
|
-
return [2 /*return*/];
|
181
|
-
}
|
182
|
-
});
|
183
|
-
});
|
184
|
-
};
|
185
|
-
//#endregion
|
186
|
-
//#region methods / add client
|
187
|
-
CompilerManager.prototype.addClient = function (client) {
|
188
|
-
// console.log(`Cilent added "${client.key}" folders`, client.folderPath)
|
189
|
-
var existed = this.clients.find(function (c) { return c === client; });
|
190
|
-
if (existed) {
|
191
|
-
tnp_helpers_1.Helpers.log("Task \"".concat(client.taskName, "\" alread added")); // TODO @LAST
|
192
|
-
}
|
193
|
-
this.clients.push(client);
|
194
|
-
};
|
195
|
-
//#endregion
|
196
|
-
//#region private methods / prevent already inited
|
197
|
-
CompilerManager.prototype.preventAlreadyInited = function () {
|
198
|
-
if (this.inited) {
|
199
|
-
tnp_helpers_1.Helpers.error("Please init Compiler Manager only once:\n CompilerManager.Instance.initScenario( ... async scenario ... );\n ", false, true);
|
200
|
-
}
|
201
|
-
};
|
202
|
-
//#endregion
|
203
|
-
//#region private methods / file should be checked
|
204
|
-
CompilerManager.prototype.fileShouldBeChecked = function (absFilePath, client) {
|
205
|
-
var fileShouldBeCached = !tnp_core_2._.isUndefined(client.folderPathContentCheck.find(function (patterFolder) {
|
206
|
-
return (0, tnp_core_2.crossPlatformPath)(absFilePath).startsWith((0, tnp_core_2.crossPlatformPath)(patterFolder));
|
207
|
-
}));
|
208
|
-
return fileShouldBeCached;
|
209
|
-
};
|
210
|
-
return CompilerManager;
|
211
|
-
}());
|
212
|
-
exports.CompilerManager = CompilerManager;
|
213
|
-
//# sourceMappingURL=compiler-manager.backend.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"compiler-manager.backend.js","sourceRoot":"","sources":["c:/Users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uB,CAC9B,CAAC;;;;;KAGH;IAED,YAAY;IAEZ,8BAA8B;IACvB,mCAAS,GAAhB,UAAiB,MAA+B;QAC9C,yEAAyE;QACzE,IAAM,OAAO,GAAG,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,UAAA,CAAC,IAAI,OAAA,CAAC,KAAK,MAAM,EAAZ,CAAY,CAAC,CAAC;QACrD,IAAI,OAAO,EAAE,CAAC;YACZ,qBAAO,CAAC,GAAG,CAAC,iBAAS,MAAM,CAAC,QAAQ,oBAAgB,CAAC,CAAC,CAAC,aAAa;QACtE,CAAC;QACD,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;IAC5B,CAAC;IACD,YAAY;IAEZ,kDAAkD;IAC1C,8CAAoB,GAA5B;QACE,IAAI,IAAI,CAAC,MAAM,EAAE,CAAC;YAChB,qBAAO,CAAC,KAAK,CACX,0HAED,EACC,KAAK,EACL,IAAI,CACL,CAAC;QACJ,CAAC;IACH,CAAC;IACD,YAAY;IAEZ,kDAAkD;IAC1C,6CAAmB,GAA3B,UACE,WAAmB,EACnB,MAA+B;QAE/B,IAAM,kBAAkB,GAAG,CAAC,YAAC,CAAC,WAAW,CACvC,MAAM,CAAC,sBAAsB,CAAC,IAAI,CAAC,UAAA,YAAY;YAC7C,OAAO,IAAA,4BAAiB,EAAC,WAAW,CAAC,CAAC,UAAU,CAC9C,IAAA,4BAAiB,EAAC,YAAY,CAAC,CAChC,CAAC;QACJ,CAAC,CAAC,CACH,CAAC;QAEF,OAAO,kBAAkB,CAAC;IAC5B,CAAC;IAEH,sBAAC;AAAD,CAAC,AAzND,IAyNC;AAzNY,0CAAe"}
|
@@ -1,5 +0,0 @@
|
|
1
|
-
export declare function AsyncAction(): (target: object, propertyKey: string, propertyDescriptor: PropertyDescriptor) => void;
|
2
|
-
export interface IncCompilerClassOptions {
|
3
|
-
className: string;
|
4
|
-
}
|
5
|
-
export declare function IncCompilerClass(options: IncCompilerClassOptions): (target: any) => void;
|
@@ -1,56 +0,0 @@
|
|
1
|
-
"use strict";
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.AsyncAction = AsyncAction;
|
4
|
-
exports.IncCompilerClass = IncCompilerClass;
|
5
|
-
//#region imports
|
6
|
-
var typescript_class_helpers_1 = require("typescript-class-helpers");
|
7
|
-
var tnp_core_1 = require("tnp-core");
|
8
|
-
var change_of_file_backend_1 = require("./change-of-file.backend");
|
9
|
-
var tnp_core_2 = require("tnp-core");
|
10
|
-
//#endregion
|
11
|
-
function AsyncAction() {
|
12
|
-
return function (target, propertyKey, propertyDescriptor) {
|
13
|
-
// get original method
|
14
|
-
// unsub(void 0, void 0);
|
15
|
-
var originalMethod = propertyDescriptor.value;
|
16
|
-
// redefine descriptor value within own function block
|
17
|
-
propertyDescriptor.value = function () {
|
18
|
-
var _this = this;
|
19
|
-
var args = [];
|
20
|
-
for (var _i = 0; _i < arguments.length; _i++) {
|
21
|
-
args[_i] = arguments[_i];
|
22
|
-
}
|
23
|
-
// log arguments before original function
|
24
|
-
// console.log(`${propertyKey} method called with args: ${JSON.stringify(args, null, 2)}`);
|
25
|
-
var first = tnp_core_1._.first(args);
|
26
|
-
if (first instanceof change_of_file_backend_1.ChangeOfFile) {
|
27
|
-
var ex = first.clientsForChange.find(function (f) {
|
28
|
-
// console.log(`${CLASS.getNameFromObject(f)} === ${CLASS.getNameFromObject(this)}`)
|
29
|
-
return typescript_class_helpers_1.CLASS.getNameFromObject(f) === typescript_class_helpers_1.CLASS.getNameFromObject(_this);
|
30
|
-
});
|
31
|
-
// console.log('ex', ex)
|
32
|
-
if (ex) {
|
33
|
-
first.executedFor.push(ex);
|
34
|
-
// console.log(`HHHH!!!!! Async Method called fror ${CLASS.getNameFromObject(this)}`);
|
35
|
-
}
|
36
|
-
}
|
37
|
-
// attach original method implementation
|
38
|
-
var result = originalMethod.apply(this, args);
|
39
|
-
// log result of method
|
40
|
-
// console.log(`${propertyKey} method return value: ${JSON.stringify(result)}`);
|
41
|
-
return result;
|
42
|
-
};
|
43
|
-
};
|
44
|
-
}
|
45
|
-
var instancesNames = [];
|
46
|
-
function IncCompilerClass(options) {
|
47
|
-
return function (target) {
|
48
|
-
var className = options.className;
|
49
|
-
if (instancesNames.includes(className)) {
|
50
|
-
tnp_core_2.Helpers.warn("Compiler class \"".concat(className, "\" already has instance."), false);
|
51
|
-
}
|
52
|
-
instancesNames.push(className);
|
53
|
-
typescript_class_helpers_1.CLASS.NAME(className)(target);
|
54
|
-
};
|
55
|
-
}
|
56
|
-
//# sourceMappingURL=decorators.backend.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"decorators.backend.js","sourceRoot":"","sources":["c:/Users/darek/projects/npm/taon-dev/incremental-compiler/src/lib/decorators.backend.ts"],"names":[],"mappings":";;AAOA,kCAgCC;AAQD,4CASC;AAxDD,iBAAiB;AACjB,qEAAiD;AACjD,qCAA6B;AAC7B,mEAAwD;AACxD,qCAAmC;AACnC,YAAY;AAEZ,SAAgB,WAAW;IACzB,OAAO,UACL,MAAc,EACd,WAAmB,EACnB,kBAAsC;QAEtC,sBAAsB;QACtB,yBAAyB;QACzB,IAAM,cAAc,GAAG,kBAAkB,CAAC,KAAK,CAAC;QAChD,sDAAsD;QACtD,kBAAkB,CAAC,KAAK,GAAG;YAAA,iBAoB1B;YApBoC,cAAc;iBAAd,UAAc,EAAd,qBAAc,EAAd,IAAc;gBAAd,yBAAc;;YACjD,yCAAyC;YACzC,+FAA+F;YAC/F,IAAM,KAAK,GAAG,YAAC,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;YAC5B,IAAI,KAAK,YAAY,qCAAY,EAAE,CAAC;gBAClC,IAAM,EAAE,GAAG,KAAK,CAAC,gBAAgB,CAAC,IAAI,CAAC,UAAA,CAAC;oBACtC,oFAAoF;oBACpF,OAAO,gCAAK,CAAC,iBAAiB,CAAC,CAAC,CAAC,KAAK,gCAAK,CAAC,iBAAiB,CAAC,KAAI,CAAC,CAAA;gBACrE,CAAC,CAAC,CAAC;gBACH,wBAAwB;gBACxB,IAAI,EAAE,EAAE,CAAC;oBACP,KAAK,CAAC,WAAW,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;oBAC3B,sFAAsF;gBACxF,CAAC;YACH,CAAC;YACD,wCAAwC;YACxC,IAAM,MAAM,GAAG,cAAc,CAAC,KAAK,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC;YAChD,uBAAuB;YACvB,iFAAiF;YACjF,OAAO,MAAM,CAAC;QAChB,CAAC,CAAA;IACH,CAAC,CAAA;AACH,CAAC;AAOD,IAAM,cAAc,GAAG,EAAE,CAAC;AAC1B,SAAgB,gBAAgB,CAAC,OAAgC;IAC/D,OAAO,UAAC,MAAM;QACJ,IAAA,SAAS,GAAK,OAAO,UAAZ,CAAa;QAC9B,IAAI,cAAc,CAAC,QAAQ,CAAC,SAAS,CAAC,EAAE,CAAC;YACvC,kBAAO,CAAC,IAAI,CAAC,2BAAmB,SAAS,6BAAyB,EAAE,KAAK,CAAC,CAAC;QAC7E,CAAC;QACD,cAAc,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC;QAC/B,gCAAK,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC,MAAM,CAAC,CAAC;IAChC,CAAC,CAAC;AACJ,CAAC"}
|
package/lib/helpers.backend.d.ts
DELETED
@@ -1,3 +0,0 @@
|
|
1
|
-
import { BaseClientCompiler } from './base-client-compiler.backend';
|
2
|
-
export declare function mapForWatching(c: string): string[];
|
3
|
-
export declare function clientsBy<T = BaseClientCompiler>(clientNameOrClass: string | Function, condition: (c: T) => boolean, clients: BaseClientCompiler[]): T[];
|
package/lib/helpers.backend.js
DELETED
@@ -1,31 +0,0 @@
|
|
1
|
-
"use strict";
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.mapForWatching = mapForWatching;
|
4
|
-
exports.clientsBy = clientsBy;
|
5
|
-
var tnp_core_1 = require("tnp-core");
|
6
|
-
var typescript_class_helpers_1 = require("typescript-class-helpers");
|
7
|
-
//#endregion
|
8
|
-
function mapForWatching(c) {
|
9
|
-
if (tnp_core_1.fse.existsSync(c) && tnp_core_1.fse.lstatSync(c).isDirectory()) {
|
10
|
-
return [c, "".concat(c, "/**/*.*")];
|
11
|
-
}
|
12
|
-
return [c];
|
13
|
-
}
|
14
|
-
function clientsBy(clientNameOrClass, condition, clients) {
|
15
|
-
if (tnp_core_1._.isFunction(clientNameOrClass)) {
|
16
|
-
clientNameOrClass = typescript_class_helpers_1.CLASS.getName(clientNameOrClass);
|
17
|
-
}
|
18
|
-
return clients.filter(function (cinstance) {
|
19
|
-
var classesOk = (typescript_class_helpers_1.CLASS.getNameFromObject(cinstance) === clientNameOrClass);
|
20
|
-
if (classesOk) {
|
21
|
-
if (tnp_core_1._.isFunction(condition)) {
|
22
|
-
return !!condition(cinstance);
|
23
|
-
}
|
24
|
-
else {
|
25
|
-
return true;
|
26
|
-
}
|
27
|
-
}
|
28
|
-
return false;
|
29
|
-
});
|
30
|
-
}
|
31
|
-
//# sourceMappingURL=helpers.backend.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"helpers.backend.js","sourceRoot":"","sources":["c:/Users/darek/projects/npm/taon-dev/incremental-compiler/src/lib/helpers.backend.ts"],"names":[],"mappings":";;AASA,wCAKC;AAED,8BAkBC;AA9BD,qCAAkC;AAElC,qEAAiD;AACjD,YAAY;AAEZ,SAAgB,cAAc,CAAC,CAAS;IACtC,IAAI,cAAG,CAAC,UAAU,CAAC,CAAC,CAAC,IAAI,cAAG,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,WAAW,EAAE,EAAE,CAAC;QACxD,OAAO,CAAC,CAAC,EAAE,UAAG,CAAC,YAAS,CAAC,CAAC;IAC5B,CAAC;IACD,OAAO,CAAC,CAAC,CAAC,CAAC;AACb,CAAC;AAED,SAAgB,SAAS,CAAyB,iBAAoC,EACpF,SAA4B,EAAE,OAA6B;IAE3D,IAAI,YAAC,CAAC,UAAU,CAAC,iBAAiB,CAAC,EAAE,CAAC;QACpC,iBAAiB,GAAG,gCAAK,CAAC,OAAO,CAAC,iBAAiB,CAAC,CAAA;IACtD,CAAC;IAED,OAAO,OAAO,CAAC,MAAM,CAAC,UAAA,SAAS;QAC7B,IAAM,SAAS,GAAG,CAAC,gCAAK,CAAC,iBAAiB,CAAC,SAAS,CAAC,KAAK,iBAAiB,CAAC,CAAC;QAC7E,IAAI,SAAS,EAAE,CAAC;YACd,IAAI,YAAC,CAAC,UAAU,CAAC,SAAS,CAAC,EAAE,CAAC;gBAC5B,OAAO,CAAC,CAAC,SAAS,CAAC,SAAgB,CAAC,CAAC;YACvC,CAAC;iBAAM,CAAC;gBACN,OAAO,IAAI,CAAC;YACd,CAAC;QACH,CAAC;QACD,OAAO,KAAK,CAAC;IACf,CAAC,CAAQ,CAAC;AACZ,CAAC"}
|
@@ -1,216 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"@angular-devkit/build-angular": "0.901.3",
|
3
|
-
"@angular-devkit/build-optimizer": "0.900.0-rc.7",
|
4
|
-
"@angular-devkit/schematics": "9.0.0-rc.7",
|
5
|
-
"@angular/animations": "9.1.3",
|
6
|
-
"@angular/cdk": "9.2.1",
|
7
|
-
"@angular/cli": "9.1.3",
|
8
|
-
"@angular/common": "9.1.3",
|
9
|
-
"@angular/compiler": "9.1.3",
|
10
|
-
"@angular/compiler-cli": "9.1.3",
|
11
|
-
"@angular/core": "9.1.3",
|
12
|
-
"@angular/forms": "9.1.3",
|
13
|
-
"@angular/http": "7.2.15",
|
14
|
-
"@angular/language-service": "9.1.3",
|
15
|
-
"@angular/material": "9.2.1",
|
16
|
-
"@angular/platform-browser": "9.1.3",
|
17
|
-
"@angular/platform-browser-dynamic": "9.1.3",
|
18
|
-
"@angular/pwa": "0.900.0-rc.7",
|
19
|
-
"@angular/router": "9.1.3",
|
20
|
-
"@angular/service-worker": "9.1.3",
|
21
|
-
"@mdi/js": "5.8.55",
|
22
|
-
"@ngx-formly/bootstrap": "5.5.6",
|
23
|
-
"@ngx-formly/core": "5.5.6",
|
24
|
-
"@ngx-formly/ionic": "5.5.6",
|
25
|
-
"@ngx-formly/material": "5.5.6",
|
26
|
-
"@ngx-loading-bar/core": "4.2.0",
|
27
|
-
"@ngx-loading-bar/http": "4.2.0",
|
28
|
-
"@ngx-loading-bar/router": "4.2.0",
|
29
|
-
"@ngx-translate/core": "11.0.1",
|
30
|
-
"@ngx-translate/http-loader": "4.0.0",
|
31
|
-
"@swimlane/ngx-datatable": "16.0.2",
|
32
|
-
"@types/chai": "4.1.2",
|
33
|
-
"@types/diff": "3.2.2",
|
34
|
-
"@types/express": "4.11.0",
|
35
|
-
"@types/express-fileupload": "0.1.1",
|
36
|
-
"@types/http-proxy": "1.16.0",
|
37
|
-
"@types/http-proxy-middleware": "0.19.2",
|
38
|
-
"@types/inquirer": "7.3.1",
|
39
|
-
"@types/jasmine": "3.5.0",
|
40
|
-
"@types/jasminewd2": "2.0.3",
|
41
|
-
"@types/json-stringify-safe": "5.0.0",
|
42
|
-
"@types/json5": "0.0.29",
|
43
|
-
"@types/lockfile": "1.0.0",
|
44
|
-
"@types/lodash": "4.14.92",
|
45
|
-
"@types/lowdb": "1.0.6",
|
46
|
-
"@types/mocha": "5.2.5",
|
47
|
-
"@types/node": "12.11.1",
|
48
|
-
"@types/node-notifier": "5.4.0",
|
49
|
-
"@types/oauth2orize": "1.8.0",
|
50
|
-
"@types/password-hash": "1.2.19",
|
51
|
-
"@types/progress": "2.0.3",
|
52
|
-
"@types/q": "1.0.3",
|
53
|
-
"@types/rimraf": "2.0.2",
|
54
|
-
"@types/systeminformation": "3.23.0",
|
55
|
-
"@types/vinyl": "2.0.2",
|
56
|
-
"@types/watch": "1.0.0",
|
57
|
-
"accepts": "1.3.4",
|
58
|
-
"angular-tree-component": "7.0.0",
|
59
|
-
"axios": "0.17.1",
|
60
|
-
"babel-cli": "6.26.0",
|
61
|
-
"babel-preset-env": "1.7.0",
|
62
|
-
"background-worker-process": "~0.0.34",
|
63
|
-
"bcryptjs": "2.4.3",
|
64
|
-
"body-parser": "1.18.2",
|
65
|
-
"bootstrap": "4.3.1",
|
66
|
-
"bs4-breakpoint": "~2.0.40",
|
67
|
-
"buffer-shims": "1.0.0",
|
68
|
-
"button-dropdown": "~1.0.45",
|
69
|
-
"callsite-record": "4.1.3",
|
70
|
-
"chai": "4.2.0",
|
71
|
-
"chalk": "2.3.2",
|
72
|
-
"check-node-version": "3.2.0",
|
73
|
-
"cheerio": "1.0.0-rc.3",
|
74
|
-
"circular-json": "0.5.1",
|
75
|
-
"codelyzer": "5.1.2",
|
76
|
-
"command-exists": "1.2.2",
|
77
|
-
"compression": "1.7.4",
|
78
|
-
"concurrently": "3.5.1",
|
79
|
-
"content-type": "1.0.4",
|
80
|
-
"cookie-parser": "1.4.3",
|
81
|
-
"copy-paste": "1.3.0",
|
82
|
-
"core-js-compat": "3.4.0",
|
83
|
-
"cors": "2.8.4",
|
84
|
-
"cpr": "3.0.1",
|
85
|
-
"cross-spawn": "7.0.3",
|
86
|
-
"detect-mocha": "0.1.0",
|
87
|
-
"diff": "3.2.0",
|
88
|
-
"element-resize-detector": "1.1.15",
|
89
|
-
"enquirer": "2.3.0",
|
90
|
-
"enum-values": "1.2.1",
|
91
|
-
"errorhandler": "1.5.0",
|
92
|
-
"eslint": "7.13.0",
|
93
|
-
"eslint-plugin-import": "2.22.1",
|
94
|
-
"eslint-plugin-jsdoc": "30.7.8",
|
95
|
-
"eslint-plugin-prefer-arrow": "1.2.2",
|
96
|
-
"express": "4.16.3",
|
97
|
-
"express-fileupload": "0.4.0",
|
98
|
-
"fbgraph": "1.4.1",
|
99
|
-
"file-loader": "1.1.5",
|
100
|
-
"fkill": "6.1.0",
|
101
|
-
"font-awesome": "4.7.0",
|
102
|
-
"fuzzy": "0.1.3",
|
103
|
-
"gulp": "3.9.1",
|
104
|
-
"hammerjs": "2.0.8",
|
105
|
-
"hostile": "1.3.3",
|
106
|
-
"html-webpack-plugin": "4.3.0",
|
107
|
-
"http-proxy": "1.16.2",
|
108
|
-
"http-proxy-middleware": "0.19.1",
|
109
|
-
"http-server": "0.11.1",
|
110
|
-
"incremental-compiler": "~1.1.52",
|
111
|
-
"inquirer": "7.3.3",
|
112
|
-
"inquirer-autocomplete-prompt": "1.3.0",
|
113
|
-
"is-elevated": "3.0.0",
|
114
|
-
"istanbul-instrumenter-loader": "2.0.0",
|
115
|
-
"jasmine-core": "3.5.0",
|
116
|
-
"jasmine-spec-reporter": "4.2.1",
|
117
|
-
"json-stringify-safe": "5.0.1",
|
118
|
-
"json10": "~1.0.34",
|
119
|
-
"json5": "2.1.3",
|
120
|
-
"json5-writer": "0.2.0",
|
121
|
-
"karma": "5.0.0",
|
122
|
-
"karma-chrome-launcher": "3.1.0",
|
123
|
-
"karma-cli": "1.0.1",
|
124
|
-
"karma-coverage-istanbul-reporter": "2.1.0",
|
125
|
-
"karma-jasmine": "3.0.1",
|
126
|
-
"karma-jasmine-html-reporter": "1.4.2",
|
127
|
-
"lnk": "1.0.1",
|
128
|
-
"lockfile": "1.0.4",
|
129
|
-
"lodash": "4.17.4",
|
130
|
-
"lodash-walk-object": "~1.0.35",
|
131
|
-
"lowdb": "1.0.0",
|
132
|
-
"magic-renamer": "~0.0.19",
|
133
|
-
"material-design-icons": "3.0.1",
|
134
|
-
"method-override": "2.3.10",
|
135
|
-
"minimist": "1.2.0",
|
136
|
-
"mkdirp": "0.5.1",
|
137
|
-
"mocha": "5.2.0",
|
138
|
-
"moment": "2.22.2",
|
139
|
-
"morphi": "~4.0.53",
|
140
|
-
"ng-modal-lib": "0.0.6",
|
141
|
-
"ng-packagr": "5.7.1",
|
142
|
-
"ng-talkback": "~2.4.24",
|
143
|
-
"ng2-file-upload": "1.3.0",
|
144
|
-
"ng2-logger": "~8.0.20",
|
145
|
-
"ng2-rest": "~11.0.41",
|
146
|
-
"ng4-icons": "~0.0.29",
|
147
|
-
"ng4-modal": "~0.0.29",
|
148
|
-
"ngx-bootstrap": "5.2.0",
|
149
|
-
"ngx-breadcrumbs": "0.0.3",
|
150
|
-
"ngx-editor": "4.1.0",
|
151
|
-
"ngx-moment": "3.5.0",
|
152
|
-
"ngx-pipes": "2.6.0",
|
153
|
-
"ngx-store": "2.1.0",
|
154
|
-
"ngx-toastr": "11.2.1",
|
155
|
-
"ngx-wig": "8.0.0",
|
156
|
-
"node-cli-test": "0.0.2",
|
157
|
-
"node-cli-tester": "~0.0.21",
|
158
|
-
"node-localstorage": "2.1.6",
|
159
|
-
"node-notifier": "6.0.0",
|
160
|
-
"nodemon": "1.14.11",
|
161
|
-
"npm-get-dependents": "1.0.1",
|
162
|
-
"npm-run": "4.1.2",
|
163
|
-
"omelette": "0.4.5",
|
164
|
-
"open": "7.2.1",
|
165
|
-
"ora": "3.4.0",
|
166
|
-
"passport": "0.3.2",
|
167
|
-
"passport-http-bearer": "1.0.1",
|
168
|
-
"password-hash": "1.2.2",
|
169
|
-
"portfinder": "1.0.21",
|
170
|
-
"prettier": "2.3.2",
|
171
|
-
"progress": "2.0.3",
|
172
|
-
"prompts": "0.1.8",
|
173
|
-
"protractor": "5.4.3",
|
174
|
-
"ps-list": "6.1.0",
|
175
|
-
"ps-node": "0.1.6",
|
176
|
-
"q": "1.5.1",
|
177
|
-
"randomcolor": "0.5.3",
|
178
|
-
"record-replay-req-res-scenario": "~0.0.25",
|
179
|
-
"reflect-metadata": "0.1.10",
|
180
|
-
"rimraf": "2.6.2",
|
181
|
-
"rxjs": "6.5.4",
|
182
|
-
"rxjs-compat": "6.5.3",
|
183
|
-
"simple-git": "1.96.0",
|
184
|
-
"sloc": "0.2.0",
|
185
|
-
"socket.io": "2.4.1",
|
186
|
-
"sort-package-json": "1.11.0",
|
187
|
-
"static-columns": "~2.0.12",
|
188
|
-
"string-similarity": "4.0.2",
|
189
|
-
"sudo-block": "3.0.0",
|
190
|
-
"systeminformation": "3.45.7",
|
191
|
-
"task.js": "0.1.5",
|
192
|
-
"tnp-cli": "~2.0.20",
|
193
|
-
"tnp-config": "~1.0.20",
|
194
|
-
"tnp-core": "~1.0.34",
|
195
|
-
"tnp-db": "~0.0.42",
|
196
|
-
"tnp-helpers": "~0.0.70",
|
197
|
-
"tnp-models": "~0.0.36",
|
198
|
-
"tnp-tools": "~0.0.45",
|
199
|
-
"tnp-ui": "~0.0.32",
|
200
|
-
"ts-loader": "7.0.4",
|
201
|
-
"ts-node": "8.3.0",
|
202
|
-
"tsickle": "0.26.0",
|
203
|
-
"tslib": "2.2.0",
|
204
|
-
"tslint": "6.1.0",
|
205
|
-
"typeorm": "~0.2.7",
|
206
|
-
"typescript": "4.1.5",
|
207
|
-
"typescript-formatter": "7.2.2",
|
208
|
-
"uglifyjs-webpack-plugin": "2.2.0",
|
209
|
-
"underscore": "1.9.1",
|
210
|
-
"uuid": "8.3.2",
|
211
|
-
"validator": "9.2.0",
|
212
|
-
"vpn-split": "~0.0.17",
|
213
|
-
"watch": "1.0.2",
|
214
|
-
"webpack-cli": "3.3.11",
|
215
|
-
"zone.js": "0.10.2"
|
216
|
-
}
|
package/package.json_tnp.json5
DELETED
@@ -1,58 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"resources": [
|
3
|
-
"README.md"
|
4
|
-
],
|
5
|
-
|
6
|
-
"overrided": {
|
7
|
-
"ignoreDepsPattern": [],
|
8
|
-
"includeAsDev": [],
|
9
|
-
|
10
|
-
"includeOnly": [
|
11
|
-
"@types/glob",
|
12
|
-
"glob",
|
13
|
-
"fs-extra",
|
14
|
-
"@types/fs-extra",
|
15
|
-
"chokidar",
|
16
|
-
"@types/chokidar",
|
17
|
-
"dateformat",
|
18
|
-
"@types/dateformat",
|
19
|
-
"typescript-class-helpers",
|
20
|
-
"tnp-helpers",
|
21
|
-
// '@parcel/watcher',
|
22
|
-
],
|
23
|
-
|
24
|
-
"dependencies": {},
|
25
|
-
"linkedFolders": [],
|
26
|
-
'npmFixes': [],
|
27
|
-
},
|
28
|
-
|
29
|
-
"linkedProjects": [],
|
30
|
-
'smartContainerBuildTarget': '',
|
31
|
-
'linkedRepos': [],
|
32
|
-
|
33
|
-
"libReleaseOptions": {
|
34
|
-
"nodts": false,
|
35
|
-
"obscure": false,
|
36
|
-
"ugly": false,
|
37
|
-
'includeNodeModules': false,
|
38
|
-
'cliBuildNoDts': false,
|
39
|
-
'cliBuildObscure': false,
|
40
|
-
'cliBuildIncludeNodeModules': false,
|
41
|
-
'cliBuildUglify': false,
|
42
|
-
},
|
43
|
-
|
44
|
-
'smartContainerTarget': '',
|
45
|
-
"type": "isomorphic-lib",
|
46
|
-
"isCoreProject": false,
|
47
|
-
"useFramework": false,
|
48
|
-
"version": 'v4',
|
49
|
-
"isGenerated": false,
|
50
|
-
"license": "MIT",
|
51
|
-
"private": false,
|
52
|
-
"main": "index.js",
|
53
|
-
"workerPlugins": {},
|
54
|
-
|
55
|
-
"additionalNpmNames": [
|
56
|
-
"firedev-incremental-watcher"
|
57
|
-
],
|
58
|
-
}
|