depflow 3.0.0-dev.6 → 3.0.0-dev.8
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/build/cli/DepFLowCLI.js +7 -5
- package/build/cli/DepFLowCLI.js.map +1 -1
- package/build/cli/bin.js +2 -5
- package/build/cli/bin.js.map +1 -1
- package/build/config/Config.d.ts +3 -3
- package/build/config/Config.js +3 -3
- package/build/config/Config.js.map +1 -1
- package/build/config/ImportMap.d.ts +24 -10
- package/build/config/ImportMap.js +38 -23
- package/build/config/ImportMap.js.map +1 -1
- package/build/config/{Tsconfig.d.ts → TSConfig.d.ts} +14 -17
- package/build/config/{Tsconfig.js → TSConfig.js} +31 -36
- package/build/config/TSConfig.js.map +1 -0
- package/build/schema/Config/Builder.d.ts +431 -0
- package/build/schema/Config/Builder.js +48 -0
- package/build/schema/Config/Builder.js.map +1 -0
- package/build/schema/Config/Config.d.ts +582 -0
- package/build/schema/Config/Config.js +20 -0
- package/build/schema/Config/Config.js.map +1 -0
- package/build/schema/Config/Dependency.d.ts +748 -0
- package/build/schema/Config/Dependency.js +25 -0
- package/build/schema/Config/Dependency.js.map +1 -0
- package/build/schema/Config/Extractor.d.ts +133 -0
- package/build/schema/Config/Extractor.js +25 -0
- package/build/schema/Config/Extractor.js.map +1 -0
- package/build/schema/Config/Resolver.d.ts +70 -0
- package/build/schema/Config/Resolver.js +25 -0
- package/build/schema/Config/Resolver.js.map +1 -0
- package/build/schema/Config/Transform.d.ts +73 -0
- package/build/schema/Config/Transform.js +27 -0
- package/build/schema/Config/Transform.js.map +1 -0
- package/build/schema/ImportMap.d.ts +22 -0
- package/build/schema/ImportMap.js +12 -0
- package/build/schema/ImportMap.js.map +1 -0
- package/build/schema/TSConfig.d.ts +56 -0
- package/build/schema/TSConfig.js +19 -0
- package/build/schema/TSConfig.js.map +1 -0
- package/build/schema/schema.d.ts +29 -0
- package/build/schema/schema.js +31 -0
- package/build/schema/schema.js.map +1 -0
- package/build/support/Builder/Builder.d.ts +10 -10
- package/build/support/Builder/Builder.js +14 -11
- package/build/support/Builder/Builder.js.map +1 -1
- package/build/support/Dependency/Dependency.d.ts +5 -5
- package/build/support/Dependency/Dependency.js +1 -1
- package/build/support/Dependency/Dependency.js.map +1 -1
- package/build/support/Dependency/GitDependency.d.ts +2 -2
- package/build/support/Dependency/GitDependency.js +1 -1
- package/build/support/Dependency/GitDependency.js.map +1 -1
- package/build/support/Dependency/NpmDependency.d.ts +3 -3
- package/build/support/Dependency/NpmDependency.js.map +1 -1
- package/build/support/PathResolver/AliasCompiler.d.ts +6 -9
- package/build/support/PathResolver/AliasCompiler.js +10 -10
- package/build/support/PathResolver/AliasCompiler.js.map +1 -1
- package/build/support/PathResolver/PathResolver.d.ts +3 -3
- package/build/support/PathResolver/PathResolver.js.map +1 -1
- package/package.json +2 -2
- package/build/config/Tsconfig.js.map +0 -1
- package/build/config/schemas.d.ts +0 -2644
- package/build/config/schemas.js +0 -90
- package/build/config/schemas.js.map +0 -1
- package/build/support/Dependency/Resolver.d.ts +0 -7
- package/build/support/Dependency/Resolver.js +0 -4
- package/build/support/Dependency/Resolver.js.map +0 -1
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { Schema } from '@netfeez/common';
|
|
2
|
+
import Builder from './Builder.js';
|
|
3
|
+
import Resolver from './Resolver.js';
|
|
4
|
+
export const GitDependency = new Schema({
|
|
5
|
+
type: 'object',
|
|
6
|
+
properties: {
|
|
7
|
+
name: { type: 'string', required: true },
|
|
8
|
+
repo: { type: 'string', required: true },
|
|
9
|
+
tag: { type: 'string', default: 'main' },
|
|
10
|
+
builder: Builder.root,
|
|
11
|
+
resolver: Resolver.root
|
|
12
|
+
}
|
|
13
|
+
});
|
|
14
|
+
export const NpmDependency = new Schema({
|
|
15
|
+
type: 'object',
|
|
16
|
+
properties: {
|
|
17
|
+
name: { type: 'string', required: true },
|
|
18
|
+
version: { type: 'string', required: true },
|
|
19
|
+
builder: Builder.root,
|
|
20
|
+
resolver: Resolver.root
|
|
21
|
+
}
|
|
22
|
+
});
|
|
23
|
+
export const Dependency = { GitDependency, NpmDependency };
|
|
24
|
+
export default Dependency;
|
|
25
|
+
//# sourceMappingURL=Dependency.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Dependency.js","sourceRoot":"","sources":["../../../src/schema/Config/Dependency.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,iBAAiB,CAAC;AACzC,OAAO,OAAO,MAAM,cAAc,CAAC;AACnC,OAAO,QAAQ,MAAM,eAAe,CAAC;AAErC,MAAM,CAAC,MAAM,aAAa,GAAG,IAAI,MAAM,CAAC;IACpC,IAAI,EAAE,QAAQ;IACd,UAAU,EAAE;QACR,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,QAAQ,EAAE,IAAI,EAAE;QACxC,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,QAAQ,EAAE,IAAI,EAAE;QACxC,GAAG,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,OAAO,EAAE,MAAM,EAAE;QACxC,OAAO,EAAE,OAAO,CAAC,IAAI;QACrB,QAAQ,EAAE,QAAQ,CAAC,IAAI;KAC1B;CACJ,CAAC,CAAC;AAIH,MAAM,CAAC,MAAM,aAAa,GAAG,IAAI,MAAM,CAAC;IACpC,IAAI,EAAE,QAAQ;IACd,UAAU,EAAE;QACR,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,QAAQ,EAAE,IAAI,EAAE;QACxC,OAAO,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,QAAQ,EAAE,IAAI,EAAE;QAC3C,OAAO,EAAE,OAAO,CAAC,IAAI;QACrB,QAAQ,EAAE,QAAQ,CAAC,IAAI;KAC1B;CACJ,CAAC,CAAC;AAIH,MAAM,CAAC,MAAM,UAAU,GAAG,EAAE,aAAa,EAAE,aAAa,EAAE,CAAC;AAK3D,eAAe,UAAU,CAAC"}
|
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
import { Schema } from '@netfeez/common';
|
|
2
|
+
export declare const ExtractorEntry: Schema<{
|
|
3
|
+
readonly type: "object";
|
|
4
|
+
readonly required: true;
|
|
5
|
+
readonly properties: {
|
|
6
|
+
readonly to: {
|
|
7
|
+
readonly type: "string";
|
|
8
|
+
readonly required: true;
|
|
9
|
+
};
|
|
10
|
+
readonly map: {
|
|
11
|
+
readonly required: false;
|
|
12
|
+
readonly type: "union";
|
|
13
|
+
readonly union: [{
|
|
14
|
+
readonly type: "string";
|
|
15
|
+
}, {
|
|
16
|
+
readonly type: "object";
|
|
17
|
+
readonly properties: {
|
|
18
|
+
readonly search: {
|
|
19
|
+
readonly type: "string";
|
|
20
|
+
readonly required: true;
|
|
21
|
+
};
|
|
22
|
+
readonly flags: {
|
|
23
|
+
readonly type: "string";
|
|
24
|
+
readonly default: "g";
|
|
25
|
+
readonly pattern: RegExp;
|
|
26
|
+
};
|
|
27
|
+
readonly replace: {
|
|
28
|
+
readonly type: "string";
|
|
29
|
+
readonly required: true;
|
|
30
|
+
};
|
|
31
|
+
};
|
|
32
|
+
}];
|
|
33
|
+
};
|
|
34
|
+
readonly transform: {
|
|
35
|
+
readonly required: false;
|
|
36
|
+
readonly type: "union";
|
|
37
|
+
readonly union: [{
|
|
38
|
+
readonly type: "string";
|
|
39
|
+
}, {
|
|
40
|
+
readonly type: "object";
|
|
41
|
+
readonly properties: {
|
|
42
|
+
readonly search: {
|
|
43
|
+
readonly type: "string";
|
|
44
|
+
readonly required: true;
|
|
45
|
+
};
|
|
46
|
+
readonly flags: {
|
|
47
|
+
readonly type: "string";
|
|
48
|
+
readonly default: "g";
|
|
49
|
+
readonly pattern: RegExp;
|
|
50
|
+
};
|
|
51
|
+
readonly replace: {
|
|
52
|
+
readonly type: "string";
|
|
53
|
+
readonly required: true;
|
|
54
|
+
};
|
|
55
|
+
};
|
|
56
|
+
}];
|
|
57
|
+
};
|
|
58
|
+
};
|
|
59
|
+
}>;
|
|
60
|
+
export type ExtractorEntry = typeof ExtractorEntry.infer;
|
|
61
|
+
export declare namespace ExtractorEntry { }
|
|
62
|
+
export declare const Extractor: Schema<{
|
|
63
|
+
readonly type: "object";
|
|
64
|
+
readonly required: true;
|
|
65
|
+
readonly allowAdditionalProperties: {
|
|
66
|
+
readonly type: "union";
|
|
67
|
+
readonly required: true;
|
|
68
|
+
readonly union: [{
|
|
69
|
+
readonly type: "string";
|
|
70
|
+
readonly required: true;
|
|
71
|
+
}, {
|
|
72
|
+
readonly type: "object";
|
|
73
|
+
readonly required: true;
|
|
74
|
+
readonly properties: {
|
|
75
|
+
readonly to: {
|
|
76
|
+
readonly type: "string";
|
|
77
|
+
readonly required: true;
|
|
78
|
+
};
|
|
79
|
+
readonly map: {
|
|
80
|
+
readonly required: false;
|
|
81
|
+
readonly type: "union";
|
|
82
|
+
readonly union: [{
|
|
83
|
+
readonly type: "string";
|
|
84
|
+
}, {
|
|
85
|
+
readonly type: "object";
|
|
86
|
+
readonly properties: {
|
|
87
|
+
readonly search: {
|
|
88
|
+
readonly type: "string";
|
|
89
|
+
readonly required: true;
|
|
90
|
+
};
|
|
91
|
+
readonly flags: {
|
|
92
|
+
readonly type: "string";
|
|
93
|
+
readonly default: "g";
|
|
94
|
+
readonly pattern: RegExp;
|
|
95
|
+
};
|
|
96
|
+
readonly replace: {
|
|
97
|
+
readonly type: "string";
|
|
98
|
+
readonly required: true;
|
|
99
|
+
};
|
|
100
|
+
};
|
|
101
|
+
}];
|
|
102
|
+
};
|
|
103
|
+
readonly transform: {
|
|
104
|
+
readonly required: false;
|
|
105
|
+
readonly type: "union";
|
|
106
|
+
readonly union: [{
|
|
107
|
+
readonly type: "string";
|
|
108
|
+
}, {
|
|
109
|
+
readonly type: "object";
|
|
110
|
+
readonly properties: {
|
|
111
|
+
readonly search: {
|
|
112
|
+
readonly type: "string";
|
|
113
|
+
readonly required: true;
|
|
114
|
+
};
|
|
115
|
+
readonly flags: {
|
|
116
|
+
readonly type: "string";
|
|
117
|
+
readonly default: "g";
|
|
118
|
+
readonly pattern: RegExp;
|
|
119
|
+
};
|
|
120
|
+
readonly replace: {
|
|
121
|
+
readonly type: "string";
|
|
122
|
+
readonly required: true;
|
|
123
|
+
};
|
|
124
|
+
};
|
|
125
|
+
}];
|
|
126
|
+
};
|
|
127
|
+
};
|
|
128
|
+
}];
|
|
129
|
+
};
|
|
130
|
+
}>;
|
|
131
|
+
export type Extractor = typeof Extractor.infer;
|
|
132
|
+
export declare namespace Extractor { }
|
|
133
|
+
export default Extractor;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { Schema } from '@netfeez/common';
|
|
2
|
+
import Transform from './Transform.js';
|
|
3
|
+
export const ExtractorEntry = new Schema({
|
|
4
|
+
type: 'object',
|
|
5
|
+
required: true,
|
|
6
|
+
properties: {
|
|
7
|
+
to: { type: 'string', required: true },
|
|
8
|
+
map: { ...Transform.root, required: false },
|
|
9
|
+
transform: { ...Transform.root, required: false }
|
|
10
|
+
}
|
|
11
|
+
});
|
|
12
|
+
export const Extractor = new Schema({
|
|
13
|
+
type: 'object',
|
|
14
|
+
required: true,
|
|
15
|
+
allowAdditionalProperties: {
|
|
16
|
+
type: 'union',
|
|
17
|
+
required: true,
|
|
18
|
+
union: [
|
|
19
|
+
{ type: 'string', required: true },
|
|
20
|
+
ExtractorEntry.root
|
|
21
|
+
]
|
|
22
|
+
}
|
|
23
|
+
});
|
|
24
|
+
export default Extractor;
|
|
25
|
+
//# sourceMappingURL=Extractor.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Extractor.js","sourceRoot":"","sources":["../../../src/schema/Config/Extractor.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,iBAAiB,CAAC;AACzC,OAAO,SAAS,MAAM,gBAAgB,CAAC;AAEvC,MAAM,CAAC,MAAM,cAAc,GAAG,IAAI,MAAM,CAAC;IACrC,IAAI,EAAE,QAAQ;IACd,QAAQ,EAAE,IAAI;IACd,UAAU,EAAE;QACR,EAAE,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,QAAQ,EAAE,IAAI,EAAE;QACtC,GAAG,EAAE,EAAE,GAAG,SAAS,CAAC,IAAI,EAAE,QAAQ,EAAE,KAAK,EAAE;QAC3C,SAAS,EAAE,EAAE,GAAG,SAAS,CAAC,IAAI,EAAE,QAAQ,EAAE,KAAK,EAAE;KACpD;CACJ,CAAC,CAAC;AAIH,MAAM,CAAC,MAAM,SAAS,GAAG,IAAI,MAAM,CAAC;IAChC,IAAI,EAAE,QAAQ;IACd,QAAQ,EAAE,IAAI;IACd,yBAAyB,EAAE;QACvB,IAAI,EAAE,OAAO;QACb,QAAQ,EAAE,IAAI;QACd,KAAK,EAAE;YACH,EAAE,IAAI,EAAE,QAAQ,EAAE,QAAQ,EAAE,IAAI,EAAE;YAClC,cAAc,CAAC,IAAI;SACtB;KACJ;CACJ,CAAC,CAAC;AAGH,eAAe,SAAS,CAAC"}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import { Schema } from '@netfeez/common';
|
|
2
|
+
export declare const TargetOptions: Schema<{
|
|
3
|
+
readonly type: "object";
|
|
4
|
+
readonly properties: {
|
|
5
|
+
readonly local: {
|
|
6
|
+
readonly type: "string";
|
|
7
|
+
readonly required: true;
|
|
8
|
+
};
|
|
9
|
+
readonly type: {
|
|
10
|
+
readonly type: "string";
|
|
11
|
+
};
|
|
12
|
+
readonly cdn: {
|
|
13
|
+
readonly type: "string";
|
|
14
|
+
};
|
|
15
|
+
};
|
|
16
|
+
}>;
|
|
17
|
+
export type TargetOptions = typeof TargetOptions.infer;
|
|
18
|
+
export declare namespace TargetOptions { }
|
|
19
|
+
export declare const Target: Schema<{
|
|
20
|
+
readonly type: "union";
|
|
21
|
+
readonly required: true;
|
|
22
|
+
readonly union: [{
|
|
23
|
+
readonly type: "string";
|
|
24
|
+
}, {
|
|
25
|
+
readonly type: "object";
|
|
26
|
+
readonly properties: {
|
|
27
|
+
readonly local: {
|
|
28
|
+
readonly type: "string";
|
|
29
|
+
readonly required: true;
|
|
30
|
+
};
|
|
31
|
+
readonly type: {
|
|
32
|
+
readonly type: "string";
|
|
33
|
+
};
|
|
34
|
+
readonly cdn: {
|
|
35
|
+
readonly type: "string";
|
|
36
|
+
};
|
|
37
|
+
};
|
|
38
|
+
}];
|
|
39
|
+
}>;
|
|
40
|
+
export type Target = typeof Target.infer;
|
|
41
|
+
export declare namespace Target { }
|
|
42
|
+
export declare const Resolver: Schema<{
|
|
43
|
+
readonly type: "object";
|
|
44
|
+
readonly required: true;
|
|
45
|
+
readonly default: {};
|
|
46
|
+
readonly allowAdditionalProperties: {
|
|
47
|
+
readonly type: "union";
|
|
48
|
+
readonly required: true;
|
|
49
|
+
readonly union: [{
|
|
50
|
+
readonly type: "string";
|
|
51
|
+
}, {
|
|
52
|
+
readonly type: "object";
|
|
53
|
+
readonly properties: {
|
|
54
|
+
readonly local: {
|
|
55
|
+
readonly type: "string";
|
|
56
|
+
readonly required: true;
|
|
57
|
+
};
|
|
58
|
+
readonly type: {
|
|
59
|
+
readonly type: "string";
|
|
60
|
+
};
|
|
61
|
+
readonly cdn: {
|
|
62
|
+
readonly type: "string";
|
|
63
|
+
};
|
|
64
|
+
};
|
|
65
|
+
}];
|
|
66
|
+
};
|
|
67
|
+
}>;
|
|
68
|
+
export type Resolver = typeof Resolver.infer;
|
|
69
|
+
export declare namespace Resolver { }
|
|
70
|
+
export default Resolver;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { Schema } from '@netfeez/common';
|
|
2
|
+
export const TargetOptions = new Schema({
|
|
3
|
+
type: 'object',
|
|
4
|
+
properties: {
|
|
5
|
+
local: { type: 'string', required: true },
|
|
6
|
+
type: { type: 'string' },
|
|
7
|
+
cdn: { type: 'string' }
|
|
8
|
+
}
|
|
9
|
+
});
|
|
10
|
+
export const Target = new Schema({
|
|
11
|
+
type: 'union',
|
|
12
|
+
required: true,
|
|
13
|
+
union: [
|
|
14
|
+
{ type: 'string' },
|
|
15
|
+
TargetOptions.root
|
|
16
|
+
]
|
|
17
|
+
});
|
|
18
|
+
export const Resolver = new Schema({
|
|
19
|
+
type: 'object',
|
|
20
|
+
required: true,
|
|
21
|
+
default: {},
|
|
22
|
+
allowAdditionalProperties: Target.root,
|
|
23
|
+
});
|
|
24
|
+
export default Resolver;
|
|
25
|
+
//# sourceMappingURL=Resolver.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Resolver.js","sourceRoot":"","sources":["../../../src/schema/Config/Resolver.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,iBAAiB,CAAC;AAEzC,MAAM,CAAC,MAAM,aAAa,GAAG,IAAI,MAAM,CAAC;IACpC,IAAI,EAAE,QAAQ;IACd,UAAU,EAAE;QACR,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,QAAQ,EAAE,IAAI,EAAE;QACzC,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;QACxB,GAAG,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;KAC1B;CACJ,CAAC,CAAC;AAIH,MAAM,CAAC,MAAM,MAAM,GAAG,IAAI,MAAM,CAAC;IAC7B,IAAI,EAAE,OAAO;IACb,QAAQ,EAAE,IAAI;IACd,KAAK,EAAE;QACH,EAAE,IAAI,EAAE,QAAQ,EAAE;QAClB,aAAa,CAAC,IAAI;KACrB;CACJ,CAAC,CAAC;AAIH,MAAM,CAAC,MAAM,QAAQ,GAAG,IAAI,MAAM,CAAC;IAC/B,IAAI,EAAE,QAAQ;IACd,QAAQ,EAAE,IAAI;IACd,OAAO,EAAE,EAAE;IACX,yBAAyB,EAAE,MAAM,CAAC,IAAI;CACzC,CAAC,CAAC;AAIH,eAAe,QAAQ,CAAC"}
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import { Schema } from '@netfeez/common';
|
|
2
|
+
export declare const TransformOptions: Schema<{
|
|
3
|
+
readonly type: "object";
|
|
4
|
+
readonly properties: {
|
|
5
|
+
readonly search: {
|
|
6
|
+
readonly type: "string";
|
|
7
|
+
readonly required: true;
|
|
8
|
+
};
|
|
9
|
+
readonly flags: {
|
|
10
|
+
readonly type: "string";
|
|
11
|
+
readonly default: "g";
|
|
12
|
+
readonly pattern: RegExp;
|
|
13
|
+
};
|
|
14
|
+
readonly replace: {
|
|
15
|
+
readonly type: "string";
|
|
16
|
+
readonly required: true;
|
|
17
|
+
};
|
|
18
|
+
};
|
|
19
|
+
}>;
|
|
20
|
+
export type TransformOptions = typeof TransformOptions.infer;
|
|
21
|
+
export declare namespace TransformOptions { }
|
|
22
|
+
export declare const GlobalTransform: Schema<{
|
|
23
|
+
readonly type: "object";
|
|
24
|
+
readonly required: true;
|
|
25
|
+
readonly properties: {
|
|
26
|
+
readonly search: {
|
|
27
|
+
readonly type: "string";
|
|
28
|
+
readonly required: true;
|
|
29
|
+
};
|
|
30
|
+
readonly flags: {
|
|
31
|
+
readonly type: "string";
|
|
32
|
+
readonly default: "g";
|
|
33
|
+
readonly pattern: RegExp;
|
|
34
|
+
};
|
|
35
|
+
readonly replace: {
|
|
36
|
+
readonly type: "string";
|
|
37
|
+
readonly required: true;
|
|
38
|
+
};
|
|
39
|
+
readonly glob: {
|
|
40
|
+
readonly type: "string";
|
|
41
|
+
readonly required: true;
|
|
42
|
+
};
|
|
43
|
+
};
|
|
44
|
+
}>;
|
|
45
|
+
export type GlobalTransform = typeof GlobalTransform.infer;
|
|
46
|
+
export declare namespace GlobalTransform { }
|
|
47
|
+
export declare const Transform: Schema<{
|
|
48
|
+
readonly type: "union";
|
|
49
|
+
readonly required: true;
|
|
50
|
+
readonly union: [{
|
|
51
|
+
readonly type: "string";
|
|
52
|
+
}, {
|
|
53
|
+
readonly type: "object";
|
|
54
|
+
readonly properties: {
|
|
55
|
+
readonly search: {
|
|
56
|
+
readonly type: "string";
|
|
57
|
+
readonly required: true;
|
|
58
|
+
};
|
|
59
|
+
readonly flags: {
|
|
60
|
+
readonly type: "string";
|
|
61
|
+
readonly default: "g";
|
|
62
|
+
readonly pattern: RegExp;
|
|
63
|
+
};
|
|
64
|
+
readonly replace: {
|
|
65
|
+
readonly type: "string";
|
|
66
|
+
readonly required: true;
|
|
67
|
+
};
|
|
68
|
+
};
|
|
69
|
+
}];
|
|
70
|
+
}>;
|
|
71
|
+
export type Transform = typeof Transform.infer;
|
|
72
|
+
export declare namespace Transform { }
|
|
73
|
+
export default Transform;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { Schema } from '@netfeez/common';
|
|
2
|
+
export const TransformOptions = new Schema({
|
|
3
|
+
type: 'object',
|
|
4
|
+
properties: {
|
|
5
|
+
search: { type: 'string', required: true },
|
|
6
|
+
flags: { type: 'string', default: 'g', pattern: /^[gimsuy]*$/ },
|
|
7
|
+
replace: { type: 'string', required: true }
|
|
8
|
+
}
|
|
9
|
+
});
|
|
10
|
+
export const GlobalTransform = new Schema({
|
|
11
|
+
type: 'object',
|
|
12
|
+
required: true,
|
|
13
|
+
properties: {
|
|
14
|
+
glob: { type: 'string', required: true },
|
|
15
|
+
...TransformOptions.root.properties,
|
|
16
|
+
}
|
|
17
|
+
});
|
|
18
|
+
export const Transform = new Schema({
|
|
19
|
+
type: 'union',
|
|
20
|
+
required: true,
|
|
21
|
+
union: [
|
|
22
|
+
{ type: 'string' },
|
|
23
|
+
TransformOptions.root
|
|
24
|
+
]
|
|
25
|
+
});
|
|
26
|
+
export default Transform;
|
|
27
|
+
//# sourceMappingURL=Transform.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Transform.js","sourceRoot":"","sources":["../../../src/schema/Config/Transform.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,iBAAiB,CAAC;AAEzC,MAAM,CAAC,MAAM,gBAAgB,GAAG,IAAI,MAAM,CAAC;IACvC,IAAI,EAAE,QAAQ;IACd,UAAU,EAAE;QACR,MAAM,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,QAAQ,EAAE,IAAI,EAAE;QAC1C,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,OAAO,EAAE,GAAG,EAAE,OAAO,EAAE,aAAa,EAAE;QAC/D,OAAO,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,QAAQ,EAAE,IAAI,EAAE;KAC9C;CACJ,CAAC,CAAC;AAIH,MAAM,CAAC,MAAM,eAAe,GAAG,IAAI,MAAM,CAAC;IACtC,IAAI,EAAE,QAAQ;IACd,QAAQ,EAAE,IAAI;IACd,UAAU,EAAE;QACR,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,QAAQ,EAAE,IAAI,EAAE;QACxC,GAAG,gBAAgB,CAAC,IAAI,CAAC,UAAU;KACtC;CACJ,CAAC,CAAC;AAIH,MAAM,CAAC,MAAM,SAAS,GAAG,IAAI,MAAM,CAAC;IAChC,IAAI,EAAE,OAAO;IACb,QAAQ,EAAE,IAAI;IACd,KAAK,EAAE;QACH,EAAE,IAAI,EAAE,QAAQ,EAAE;QAClB,gBAAgB,CAAC,IAAI;KACxB;CACJ,CAAC,CAAC;AAIH,eAAe,SAAS,CAAC"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { Schema } from '@netfeez/common';
|
|
2
|
+
export declare const ImportMap: Schema<{
|
|
3
|
+
readonly type: "object";
|
|
4
|
+
readonly allowAdditionalProperties: true;
|
|
5
|
+
readonly default: {};
|
|
6
|
+
readonly properties: {
|
|
7
|
+
readonly imports: {
|
|
8
|
+
readonly type: "object";
|
|
9
|
+
readonly allowAdditionalProperties: true;
|
|
10
|
+
readonly default: {};
|
|
11
|
+
};
|
|
12
|
+
readonly scopes: {
|
|
13
|
+
readonly type: "object";
|
|
14
|
+
readonly allowAdditionalProperties: true;
|
|
15
|
+
readonly default: {};
|
|
16
|
+
};
|
|
17
|
+
};
|
|
18
|
+
}>;
|
|
19
|
+
export declare namespace ImportMap {
|
|
20
|
+
type Root = typeof ImportMap.infer;
|
|
21
|
+
}
|
|
22
|
+
export default ImportMap;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Schema } from '@netfeez/common';
|
|
2
|
+
export const ImportMap = new Schema({
|
|
3
|
+
type: 'object',
|
|
4
|
+
allowAdditionalProperties: true,
|
|
5
|
+
default: {},
|
|
6
|
+
properties: {
|
|
7
|
+
imports: { type: 'object', allowAdditionalProperties: true, default: {} },
|
|
8
|
+
scopes: { type: 'object', allowAdditionalProperties: true, default: {} }
|
|
9
|
+
}
|
|
10
|
+
});
|
|
11
|
+
export default ImportMap;
|
|
12
|
+
//# sourceMappingURL=ImportMap.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ImportMap.js","sourceRoot":"","sources":["../../src/schema/ImportMap.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,iBAAiB,CAAC;AAEzC,MAAM,CAAC,MAAM,SAAS,GAAG,IAAI,MAAM,CAAC;IAChC,IAAI,EAAE,QAAQ;IACd,yBAAyB,EAAE,IAAI;IAC/B,OAAO,EAAE,EAAE;IACX,UAAU,EAAE;QACR,OAAO,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,yBAAyB,EAAE,IAAI,EAAE,OAAO,EAAE,EAAE,EAAE;QACzE,MAAM,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,yBAAyB,EAAE,IAAI,EAAE,OAAO,EAAE,EAAE,EAAE;KAC3E;CACJ,CAAC,CAAC;AAMH,eAAe,SAAS,CAAC"}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { Schema } from '@netfeez/common';
|
|
2
|
+
export declare const CompilerOptions: Schema<{
|
|
3
|
+
readonly type: "object";
|
|
4
|
+
readonly allowAdditionalProperties: true;
|
|
5
|
+
readonly properties: {
|
|
6
|
+
readonly rootDir: {
|
|
7
|
+
readonly type: "string";
|
|
8
|
+
};
|
|
9
|
+
readonly outDir: {
|
|
10
|
+
readonly type: "string";
|
|
11
|
+
};
|
|
12
|
+
readonly paths: {
|
|
13
|
+
readonly type: "object";
|
|
14
|
+
readonly allowAdditionalProperties: {
|
|
15
|
+
readonly type: "array";
|
|
16
|
+
readonly items: {
|
|
17
|
+
readonly type: "string";
|
|
18
|
+
};
|
|
19
|
+
};
|
|
20
|
+
};
|
|
21
|
+
};
|
|
22
|
+
}>;
|
|
23
|
+
export declare const TSConfig: Schema<{
|
|
24
|
+
readonly type: "object";
|
|
25
|
+
readonly allowAdditionalProperties: true;
|
|
26
|
+
readonly properties: {
|
|
27
|
+
readonly compilerOptions: {
|
|
28
|
+
readonly type: "object";
|
|
29
|
+
readonly allowAdditionalProperties: true;
|
|
30
|
+
readonly properties: {
|
|
31
|
+
readonly rootDir: {
|
|
32
|
+
readonly type: "string";
|
|
33
|
+
};
|
|
34
|
+
readonly outDir: {
|
|
35
|
+
readonly type: "string";
|
|
36
|
+
};
|
|
37
|
+
readonly paths: {
|
|
38
|
+
readonly type: "object";
|
|
39
|
+
readonly allowAdditionalProperties: {
|
|
40
|
+
readonly type: "array";
|
|
41
|
+
readonly items: {
|
|
42
|
+
readonly type: "string";
|
|
43
|
+
};
|
|
44
|
+
};
|
|
45
|
+
};
|
|
46
|
+
};
|
|
47
|
+
};
|
|
48
|
+
};
|
|
49
|
+
}>;
|
|
50
|
+
export declare namespace TSConfig {
|
|
51
|
+
namespace Root {
|
|
52
|
+
type CompilerOptions = typeof CompilerOptions.infer;
|
|
53
|
+
}
|
|
54
|
+
type Root = typeof TSConfig.infer;
|
|
55
|
+
}
|
|
56
|
+
export default TSConfig;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { Schema } from '@netfeez/common';
|
|
2
|
+
export const CompilerOptions = new Schema({
|
|
3
|
+
type: 'object',
|
|
4
|
+
allowAdditionalProperties: true,
|
|
5
|
+
properties: {
|
|
6
|
+
rootDir: { type: 'string' },
|
|
7
|
+
outDir: { type: 'string' },
|
|
8
|
+
paths: { type: 'object', allowAdditionalProperties: { type: 'array', items: { type: 'string' } } }
|
|
9
|
+
}
|
|
10
|
+
});
|
|
11
|
+
export const TSConfig = new Schema({
|
|
12
|
+
type: 'object',
|
|
13
|
+
allowAdditionalProperties: true,
|
|
14
|
+
properties: {
|
|
15
|
+
compilerOptions: CompilerOptions.root
|
|
16
|
+
}
|
|
17
|
+
});
|
|
18
|
+
export default TSConfig;
|
|
19
|
+
//# sourceMappingURL=TSConfig.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TSConfig.js","sourceRoot":"","sources":["../../src/schema/TSConfig.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,iBAAiB,CAAC;AAEzC,MAAM,CAAC,MAAM,eAAe,GAAG,IAAI,MAAM,CAAC;IACtC,IAAI,EAAE,QAAQ;IACd,yBAAyB,EAAE,IAAI;IAC/B,UAAU,EAAE;QACR,OAAO,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;QAC3B,MAAM,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;QAC1B,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,yBAAyB,EAAE,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE,EAAE;KACrG;CACJ,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,QAAQ,GAAG,IAAI,MAAM,CAAC;IAC/B,IAAI,EAAE,QAAQ;IACd,yBAAyB,EAAE,IAAI;IAC/B,UAAU,EAAE;QACR,eAAe,EAAE,eAAe,CAAC,IAAI;KACxC;CACJ,CAAC,CAAC;AASH,eAAe,QAAQ,CAAC"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import _TSConfig from './TSConfig.js';
|
|
2
|
+
import _ImportMap from './ImportMap.js';
|
|
3
|
+
import _Config from './Config/Config.js';
|
|
4
|
+
import _Resolver, { Target as _Target } from './Config/Resolver.js';
|
|
5
|
+
import _Transform, { GlobalTransform as _GlobalTransform } from './Config/Transform.js';
|
|
6
|
+
import _Extractor from './Config/Extractor.js';
|
|
7
|
+
import _Builder from './Config/Builder.js';
|
|
8
|
+
import _Dependency from './Config/Dependency.js';
|
|
9
|
+
export { TSConfig } from './TSConfig.js';
|
|
10
|
+
export { ImportMap } from './ImportMap.js';
|
|
11
|
+
export { Config } from './Config/Config.js';
|
|
12
|
+
export { Resolver, Target } from './Config/Resolver.js';
|
|
13
|
+
export { Transform, GlobalTransform } from './Config/Transform.js';
|
|
14
|
+
export { Extractor } from './Config/Extractor.js';
|
|
15
|
+
export { Builder } from './Config/Builder.js';
|
|
16
|
+
export { Dependency } from './Config/Dependency.js';
|
|
17
|
+
export declare namespace schema {
|
|
18
|
+
export import TSConfig = _TSConfig;
|
|
19
|
+
export import ImportMap = _ImportMap;
|
|
20
|
+
export import Config = _Config;
|
|
21
|
+
export import Resolver = _Resolver;
|
|
22
|
+
export import Target = _Target;
|
|
23
|
+
export import Transform = _Transform;
|
|
24
|
+
export import GlobalTransform = _GlobalTransform;
|
|
25
|
+
export import Extractor = _Extractor;
|
|
26
|
+
export import Builder = _Builder;
|
|
27
|
+
export import Dependency = _Dependency;
|
|
28
|
+
}
|
|
29
|
+
export default schema;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import _TSConfig from './TSConfig.js';
|
|
2
|
+
import _ImportMap from './ImportMap.js';
|
|
3
|
+
import _Config from './Config/Config.js';
|
|
4
|
+
import _Resolver, { Target as _Target } from './Config/Resolver.js';
|
|
5
|
+
import _Transform, { GlobalTransform as _GlobalTransform } from './Config/Transform.js';
|
|
6
|
+
import _Extractor from './Config/Extractor.js';
|
|
7
|
+
import _Builder from './Config/Builder.js';
|
|
8
|
+
import _Dependency from './Config/Dependency.js';
|
|
9
|
+
export { TSConfig } from './TSConfig.js';
|
|
10
|
+
export { ImportMap } from './ImportMap.js';
|
|
11
|
+
export { Config } from './Config/Config.js';
|
|
12
|
+
export { Resolver, Target } from './Config/Resolver.js';
|
|
13
|
+
export { Transform, GlobalTransform } from './Config/Transform.js';
|
|
14
|
+
export { Extractor } from './Config/Extractor.js';
|
|
15
|
+
export { Builder } from './Config/Builder.js';
|
|
16
|
+
export { Dependency } from './Config/Dependency.js';
|
|
17
|
+
export var schema;
|
|
18
|
+
(function (schema) {
|
|
19
|
+
schema.TSConfig = _TSConfig;
|
|
20
|
+
schema.ImportMap = _ImportMap;
|
|
21
|
+
schema.Config = _Config;
|
|
22
|
+
schema.Resolver = _Resolver;
|
|
23
|
+
schema.Target = _Target;
|
|
24
|
+
schema.Transform = _Transform;
|
|
25
|
+
schema.GlobalTransform = _GlobalTransform;
|
|
26
|
+
schema.Extractor = _Extractor;
|
|
27
|
+
schema.Builder = _Builder;
|
|
28
|
+
schema.Dependency = _Dependency;
|
|
29
|
+
})(schema || (schema = {}));
|
|
30
|
+
export default schema;
|
|
31
|
+
//# sourceMappingURL=schema.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schema.js","sourceRoot":"","sources":["../../src/schema/schema.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,eAAe,CAAC;AACtC,OAAO,UAAU,MAAM,gBAAgB,CAAC;AACxC,OAAO,OAAO,MAAM,oBAAoB,CAAC;AACzC,OAAO,SAAS,EAAE,EAAE,MAAM,IAAI,OAAO,EAAE,MAAM,sBAAsB,CAAC;AACpE,OAAO,UAAU,EAAE,EAAE,eAAe,IAAI,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AACxF,OAAO,UAAU,MAAM,uBAAuB,CAAC;AAC/C,OAAO,QAAQ,MAAM,qBAAqB,CAAC;AAC3C,OAAO,WAAW,MAAM,wBAAwB,CAAC;AAEjD,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AACzC,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAC3C,OAAO,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAC5C,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AACxD,OAAO,EAAE,SAAS,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACnE,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAClD,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAC9C,OAAO,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAC;AAEpD,MAAM,KAAW,MAAM,CAWtB;AAXD,WAAiB,MAAM;IACL,eAAQ,GAAG,SAAS,CAAC;IACrB,gBAAS,GAAG,UAAU,CAAC;IACvB,aAAM,GAAG,OAAO,CAAC;IACjB,eAAQ,GAAG,SAAS,CAAC;IACrB,aAAM,GAAG,OAAO,CAAC;IACjB,gBAAS,GAAG,UAAU,CAAC;IACvB,sBAAe,GAAG,gBAAgB,CAAC;IACnC,gBAAS,GAAG,UAAU,CAAC;IACvB,cAAO,GAAG,QAAQ,CAAC;IACnB,iBAAU,GAAG,WAAW,CAAC;AAC3C,CAAC,EAXgB,MAAM,KAAN,MAAM,QAWtB;AAED,eAAe,MAAM,CAAC"}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import type Logger from "@netfeez/vterm";
|
|
2
|
-
import
|
|
2
|
+
import schema from "../../schema/schema.js";
|
|
3
3
|
export declare class Builder {
|
|
4
|
-
protected readonly pipeline: Builder.
|
|
4
|
+
protected readonly pipeline: Builder.Builder;
|
|
5
5
|
protected readonly cwd: string;
|
|
6
6
|
protected readonly logger: Logger | null;
|
|
7
7
|
constructor(info: Builder.Info);
|
|
8
8
|
run(): Promise<void>;
|
|
9
|
-
protected runGlobalTransform(options:
|
|
9
|
+
protected runGlobalTransform(options: schema.GlobalTransform): Promise<void>;
|
|
10
10
|
/**
|
|
11
11
|
* Runs the extraction process based on the provided entry configuration, which can be either a string or an array of extraction entries.
|
|
12
12
|
* It handles the copying of files from the specified source to the target location, applying any necessary path transformations based on the provided replacer configuration.
|
|
@@ -15,7 +15,7 @@ export declare class Builder {
|
|
|
15
15
|
* @returns A promise that resolves when the extraction process is complete, or rejects with an error if any issues occur during the file copying or transformation.
|
|
16
16
|
* @throws Will throw an error if any issues occur during the file copying process, such as problems with reading or writing files, or if the provided entry configuration is invalid.
|
|
17
17
|
*/
|
|
18
|
-
protected runExtractor(entry: string | Builder.Extractor
|
|
18
|
+
protected runExtractor(entry: string | Builder.Extractor): Promise<void>;
|
|
19
19
|
/**
|
|
20
20
|
* Runs a series of shell commands as part of the build process, using a child process to execute the commands and capturing the output for logging. It handles the execution of the commands, providing feedback on the progress and any errors that occur during the process. This method is essential for executing the necessary setup commands defined in the builder configuration, allowing for a flexible and dynamic build process that can accommodate various requirements for different dependencies.
|
|
21
21
|
* @param commands An array of strings representing the shell commands to be executed as part of the build process.
|
|
@@ -30,15 +30,15 @@ export declare class Builder {
|
|
|
30
30
|
* @returns A function that takes a string as input and returns a new string with the specified replacements applied, based on the provided replacer configuration.
|
|
31
31
|
* @throws Will throw an error if the provided replacer configuration is invalid, such as if it is neither a string nor an object with the required properties.
|
|
32
32
|
*/
|
|
33
|
-
protected static replacer(replacer
|
|
33
|
+
protected static replacer(replacer?: schema.Transform): Builder.Transformer;
|
|
34
34
|
}
|
|
35
35
|
export declare namespace Builder {
|
|
36
|
-
type
|
|
37
|
-
type
|
|
38
|
-
type
|
|
39
|
-
type Extractor =
|
|
36
|
+
type Transformer = (str: string) => string;
|
|
37
|
+
type Transform = schema.Transform;
|
|
38
|
+
type Builder = schema.Builder;
|
|
39
|
+
type Extractor = schema.Extractor;
|
|
40
40
|
interface Info {
|
|
41
|
-
pipeline:
|
|
41
|
+
pipeline: Builder;
|
|
42
42
|
cwd: string;
|
|
43
43
|
logger?: Logger | null;
|
|
44
44
|
}
|