@uipath/api-workflow-tool 1.199.0 → 1.200.0-preview.117
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/dist/browser-strategy-d4zm14fb.js +99 -0
- package/dist/browser-xef2n2gy.js +1795 -0
- package/dist/index-45nhp2zp.js +39797 -0
- package/dist/index-xd9d4vm5.js +722 -0
- package/dist/index.js +16 -2147
- package/dist/index.umd.min-drpc57vn.js +7814 -0
- package/dist/node-8r7q8pra.js +13909 -0
- package/dist/node-strategy-7bvg07kx.js +63 -0
- package/dist/packager-tool-1ps2qeqg.js +10 -0
- package/dist/packager-tool-1v8fmky0.js +1378 -0
- package/dist/packager-tool-4f38v0ry.js +1161 -0
- package/dist/packager-tool-9qecd4wb.js +14 -0
- package/dist/packager-tool-9yfnj0t1.js +12309 -0
- package/dist/packager-tool-gd8cthdr.js +40566 -0
- package/dist/packager-tool-h1tyrbff.js +2360 -0
- package/dist/packager-tool-wckvcay0.js +50 -0
- package/dist/packager-tool-y7hv8v54.js +8944 -0
- package/dist/packager-tool.js +8 -3299
- package/dist/tool.js +12 -100551
- package/package.json +4 -3
|
@@ -0,0 +1,1378 @@
|
|
|
1
|
+
import {
|
|
2
|
+
I18nManager,
|
|
3
|
+
NugetConstants,
|
|
4
|
+
NugetPackager,
|
|
5
|
+
Path,
|
|
6
|
+
ProjectTool,
|
|
7
|
+
ProjectTypes,
|
|
8
|
+
TemporaryStorageService,
|
|
9
|
+
ToolErrorCodes,
|
|
10
|
+
ToolResult,
|
|
11
|
+
ensureContentOperateFile,
|
|
12
|
+
translate
|
|
13
|
+
} from "./packager-tool-h1tyrbff.js";
|
|
14
|
+
// ../packager/packager-tool-apiworkflow/src/i18n/locales/de.json
|
|
15
|
+
var de_default = {
|
|
16
|
+
toolApiworkflow: {
|
|
17
|
+
info: {
|
|
18
|
+
restoreNotRequired: "Restore operation is not required for API projects",
|
|
19
|
+
validateNotRequired: "Validate operation is not required for API projects",
|
|
20
|
+
disposing: "Disposing API Workflows Tool"
|
|
21
|
+
},
|
|
22
|
+
progress: {
|
|
23
|
+
copyingFiles: "Copying files...",
|
|
24
|
+
creatingOperateFile: "Creating operate.json file...",
|
|
25
|
+
creatingPackageDescriptor: "Creating package-descriptor.json file...",
|
|
26
|
+
creatingNugetPackage: "Creating NuGet package...",
|
|
27
|
+
packageCreatedSuccessfully: "Package created successfully"
|
|
28
|
+
},
|
|
29
|
+
success: {
|
|
30
|
+
done: "done"
|
|
31
|
+
},
|
|
32
|
+
errors: {
|
|
33
|
+
buildFailed: "An error occurred while building API project files",
|
|
34
|
+
packFailed: "An error occurred while packing API project"
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
};
|
|
38
|
+
|
|
39
|
+
// ../packager/packager-tool-apiworkflow/src/i18n/locales/en.ts
|
|
40
|
+
var en = {
|
|
41
|
+
toolApiworkflow: {
|
|
42
|
+
info: {
|
|
43
|
+
restoreNotRequired: "Restore operation is not required for API projects",
|
|
44
|
+
validateNotRequired: "Validate operation is not required for API projects",
|
|
45
|
+
disposing: "Disposing API Workflows Tool"
|
|
46
|
+
},
|
|
47
|
+
progress: {
|
|
48
|
+
copyingFiles: "Copying files...",
|
|
49
|
+
creatingOperateFile: "Creating operate.json file...",
|
|
50
|
+
creatingPackageDescriptor: "Creating package-descriptor.json file...",
|
|
51
|
+
creatingNugetPackage: "Creating NuGet package...",
|
|
52
|
+
packageCreatedSuccessfully: "Package created successfully"
|
|
53
|
+
},
|
|
54
|
+
success: {
|
|
55
|
+
done: "done"
|
|
56
|
+
},
|
|
57
|
+
errors: {
|
|
58
|
+
buildFailed: "An error occurred while building API project files",
|
|
59
|
+
packFailed: "An error occurred while packing API project"
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
};
|
|
63
|
+
// ../packager/packager-tool-apiworkflow/src/i18n/locales/es.json
|
|
64
|
+
var es_default = {
|
|
65
|
+
toolApiworkflow: {
|
|
66
|
+
info: {
|
|
67
|
+
restoreNotRequired: "Restore operation is not required for API projects",
|
|
68
|
+
validateNotRequired: "Validate operation is not required for API projects",
|
|
69
|
+
disposing: "Disposing API Workflows Tool"
|
|
70
|
+
},
|
|
71
|
+
progress: {
|
|
72
|
+
copyingFiles: "Copying files...",
|
|
73
|
+
creatingOperateFile: "Creating operate.json file...",
|
|
74
|
+
creatingPackageDescriptor: "Creating package-descriptor.json file...",
|
|
75
|
+
creatingNugetPackage: "Creating NuGet package...",
|
|
76
|
+
packageCreatedSuccessfully: "Package created successfully"
|
|
77
|
+
},
|
|
78
|
+
success: {
|
|
79
|
+
done: "done"
|
|
80
|
+
},
|
|
81
|
+
errors: {
|
|
82
|
+
buildFailed: "An error occurred while building API project files",
|
|
83
|
+
packFailed: "An error occurred while packing API project"
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
};
|
|
87
|
+
// ../packager/packager-tool-apiworkflow/src/i18n/locales/es-MX.json
|
|
88
|
+
var es_MX_default = {
|
|
89
|
+
toolApiworkflow: {
|
|
90
|
+
info: {
|
|
91
|
+
restoreNotRequired: "Restore operation is not required for API projects",
|
|
92
|
+
validateNotRequired: "Validate operation is not required for API projects",
|
|
93
|
+
disposing: "Disposing API Workflows Tool"
|
|
94
|
+
},
|
|
95
|
+
progress: {
|
|
96
|
+
copyingFiles: "Copying files...",
|
|
97
|
+
creatingOperateFile: "Creating operate.json file...",
|
|
98
|
+
creatingPackageDescriptor: "Creating package-descriptor.json file...",
|
|
99
|
+
creatingNugetPackage: "Creating NuGet package...",
|
|
100
|
+
packageCreatedSuccessfully: "Package created successfully"
|
|
101
|
+
},
|
|
102
|
+
success: {
|
|
103
|
+
done: "done"
|
|
104
|
+
},
|
|
105
|
+
errors: {
|
|
106
|
+
buildFailed: "An error occurred while building API project files",
|
|
107
|
+
packFailed: "An error occurred while packing API project"
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
};
|
|
111
|
+
// ../packager/packager-tool-apiworkflow/src/i18n/locales/fr.json
|
|
112
|
+
var fr_default = {
|
|
113
|
+
toolApiworkflow: {
|
|
114
|
+
info: {
|
|
115
|
+
restoreNotRequired: "Restore operation is not required for API projects",
|
|
116
|
+
validateNotRequired: "Validate operation is not required for API projects",
|
|
117
|
+
disposing: "Disposing API Workflows Tool"
|
|
118
|
+
},
|
|
119
|
+
progress: {
|
|
120
|
+
copyingFiles: "Copying files...",
|
|
121
|
+
creatingOperateFile: "Creating operate.json file...",
|
|
122
|
+
creatingPackageDescriptor: "Creating package-descriptor.json file...",
|
|
123
|
+
creatingNugetPackage: "Creating NuGet package...",
|
|
124
|
+
packageCreatedSuccessfully: "Package created successfully"
|
|
125
|
+
},
|
|
126
|
+
success: {
|
|
127
|
+
done: "done"
|
|
128
|
+
},
|
|
129
|
+
errors: {
|
|
130
|
+
buildFailed: "An error occurred while building API project files",
|
|
131
|
+
packFailed: "An error occurred while packing API project"
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
};
|
|
135
|
+
// ../packager/packager-tool-apiworkflow/src/i18n/locales/ja.json
|
|
136
|
+
var ja_default = {
|
|
137
|
+
toolApiworkflow: {
|
|
138
|
+
info: {
|
|
139
|
+
restoreNotRequired: "Restore operation is not required for API projects",
|
|
140
|
+
validateNotRequired: "Validate operation is not required for API projects",
|
|
141
|
+
disposing: "Disposing API Workflows Tool"
|
|
142
|
+
},
|
|
143
|
+
progress: {
|
|
144
|
+
copyingFiles: "Copying files...",
|
|
145
|
+
creatingOperateFile: "Creating operate.json file...",
|
|
146
|
+
creatingPackageDescriptor: "Creating package-descriptor.json file...",
|
|
147
|
+
creatingNugetPackage: "Creating NuGet package...",
|
|
148
|
+
packageCreatedSuccessfully: "Package created successfully"
|
|
149
|
+
},
|
|
150
|
+
success: {
|
|
151
|
+
done: "done"
|
|
152
|
+
},
|
|
153
|
+
errors: {
|
|
154
|
+
buildFailed: "An error occurred while building API project files",
|
|
155
|
+
packFailed: "An error occurred while packing API project"
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
};
|
|
159
|
+
// ../packager/packager-tool-apiworkflow/src/i18n/locales/ko.json
|
|
160
|
+
var ko_default = {
|
|
161
|
+
toolApiworkflow: {
|
|
162
|
+
info: {
|
|
163
|
+
restoreNotRequired: "Restore operation is not required for API projects",
|
|
164
|
+
validateNotRequired: "Validate operation is not required for API projects",
|
|
165
|
+
disposing: "Disposing API Workflows Tool"
|
|
166
|
+
},
|
|
167
|
+
progress: {
|
|
168
|
+
copyingFiles: "Copying files...",
|
|
169
|
+
creatingOperateFile: "Creating operate.json file...",
|
|
170
|
+
creatingPackageDescriptor: "Creating package-descriptor.json file...",
|
|
171
|
+
creatingNugetPackage: "Creating NuGet package...",
|
|
172
|
+
packageCreatedSuccessfully: "Package created successfully"
|
|
173
|
+
},
|
|
174
|
+
success: {
|
|
175
|
+
done: "done"
|
|
176
|
+
},
|
|
177
|
+
errors: {
|
|
178
|
+
buildFailed: "An error occurred while building API project files",
|
|
179
|
+
packFailed: "An error occurred while packing API project"
|
|
180
|
+
}
|
|
181
|
+
}
|
|
182
|
+
};
|
|
183
|
+
// ../packager/packager-tool-apiworkflow/src/i18n/locales/pt.json
|
|
184
|
+
var pt_default = {
|
|
185
|
+
toolApiworkflow: {
|
|
186
|
+
info: {
|
|
187
|
+
restoreNotRequired: "Restore operation is not required for API projects",
|
|
188
|
+
validateNotRequired: "Validate operation is not required for API projects",
|
|
189
|
+
disposing: "Disposing API Workflows Tool"
|
|
190
|
+
},
|
|
191
|
+
progress: {
|
|
192
|
+
copyingFiles: "Copying files...",
|
|
193
|
+
creatingOperateFile: "Creating operate.json file...",
|
|
194
|
+
creatingPackageDescriptor: "Creating package-descriptor.json file...",
|
|
195
|
+
creatingNugetPackage: "Creating NuGet package...",
|
|
196
|
+
packageCreatedSuccessfully: "Package created successfully"
|
|
197
|
+
},
|
|
198
|
+
success: {
|
|
199
|
+
done: "done"
|
|
200
|
+
},
|
|
201
|
+
errors: {
|
|
202
|
+
buildFailed: "An error occurred while building API project files",
|
|
203
|
+
packFailed: "An error occurred while packing API project"
|
|
204
|
+
}
|
|
205
|
+
}
|
|
206
|
+
};
|
|
207
|
+
// ../packager/packager-tool-apiworkflow/src/i18n/locales/pt-BR.json
|
|
208
|
+
var pt_BR_default = {
|
|
209
|
+
toolApiworkflow: {
|
|
210
|
+
info: {
|
|
211
|
+
restoreNotRequired: "Restore operation is not required for API projects",
|
|
212
|
+
validateNotRequired: "Validate operation is not required for API projects",
|
|
213
|
+
disposing: "Disposing API Workflows Tool"
|
|
214
|
+
},
|
|
215
|
+
progress: {
|
|
216
|
+
copyingFiles: "Copying files...",
|
|
217
|
+
creatingOperateFile: "Creating operate.json file...",
|
|
218
|
+
creatingPackageDescriptor: "Creating package-descriptor.json file...",
|
|
219
|
+
creatingNugetPackage: "Creating NuGet package...",
|
|
220
|
+
packageCreatedSuccessfully: "Package created successfully"
|
|
221
|
+
},
|
|
222
|
+
success: {
|
|
223
|
+
done: "done"
|
|
224
|
+
},
|
|
225
|
+
errors: {
|
|
226
|
+
buildFailed: "An error occurred while building API project files",
|
|
227
|
+
packFailed: "An error occurred while packing API project"
|
|
228
|
+
}
|
|
229
|
+
}
|
|
230
|
+
};
|
|
231
|
+
// ../packager/packager-tool-apiworkflow/src/i18n/locales/ro.json
|
|
232
|
+
var ro_default = {
|
|
233
|
+
toolApiworkflow: {
|
|
234
|
+
info: {
|
|
235
|
+
restoreNotRequired: "Restore operation is not required for API projects",
|
|
236
|
+
validateNotRequired: "Validate operation is not required for API projects",
|
|
237
|
+
disposing: "Disposing API Workflows Tool"
|
|
238
|
+
},
|
|
239
|
+
progress: {
|
|
240
|
+
copyingFiles: "Copying files...",
|
|
241
|
+
creatingOperateFile: "Creating operate.json file...",
|
|
242
|
+
creatingPackageDescriptor: "Creating package-descriptor.json file...",
|
|
243
|
+
creatingNugetPackage: "Creating NuGet package...",
|
|
244
|
+
packageCreatedSuccessfully: "Package created successfully"
|
|
245
|
+
},
|
|
246
|
+
success: {
|
|
247
|
+
done: "done"
|
|
248
|
+
},
|
|
249
|
+
errors: {
|
|
250
|
+
buildFailed: "An error occurred while building API project files",
|
|
251
|
+
packFailed: "An error occurred while packing API project"
|
|
252
|
+
}
|
|
253
|
+
}
|
|
254
|
+
};
|
|
255
|
+
// ../packager/packager-tool-apiworkflow/src/i18n/locales/ru.json
|
|
256
|
+
var ru_default = {
|
|
257
|
+
toolApiworkflow: {
|
|
258
|
+
info: {
|
|
259
|
+
restoreNotRequired: "Restore operation is not required for API projects",
|
|
260
|
+
validateNotRequired: "Validate operation is not required for API projects",
|
|
261
|
+
disposing: "Disposing API Workflows Tool"
|
|
262
|
+
},
|
|
263
|
+
progress: {
|
|
264
|
+
copyingFiles: "Copying files...",
|
|
265
|
+
creatingOperateFile: "Creating operate.json file...",
|
|
266
|
+
creatingPackageDescriptor: "Creating package-descriptor.json file...",
|
|
267
|
+
creatingNugetPackage: "Creating NuGet package...",
|
|
268
|
+
packageCreatedSuccessfully: "Package created successfully"
|
|
269
|
+
},
|
|
270
|
+
success: {
|
|
271
|
+
done: "done"
|
|
272
|
+
},
|
|
273
|
+
errors: {
|
|
274
|
+
buildFailed: "An error occurred while building API project files",
|
|
275
|
+
packFailed: "An error occurred while packing API project"
|
|
276
|
+
}
|
|
277
|
+
}
|
|
278
|
+
};
|
|
279
|
+
// ../packager/packager-tool-apiworkflow/src/i18n/locales/tr.json
|
|
280
|
+
var tr_default = {
|
|
281
|
+
toolApiworkflow: {
|
|
282
|
+
info: {
|
|
283
|
+
restoreNotRequired: "Restore operation is not required for API projects",
|
|
284
|
+
validateNotRequired: "Validate operation is not required for API projects",
|
|
285
|
+
disposing: "Disposing API Workflows Tool"
|
|
286
|
+
},
|
|
287
|
+
progress: {
|
|
288
|
+
copyingFiles: "Copying files...",
|
|
289
|
+
creatingOperateFile: "Creating operate.json file...",
|
|
290
|
+
creatingPackageDescriptor: "Creating package-descriptor.json file...",
|
|
291
|
+
creatingNugetPackage: "Creating NuGet package...",
|
|
292
|
+
packageCreatedSuccessfully: "Package created successfully"
|
|
293
|
+
},
|
|
294
|
+
success: {
|
|
295
|
+
done: "done"
|
|
296
|
+
},
|
|
297
|
+
errors: {
|
|
298
|
+
buildFailed: "An error occurred while building API project files",
|
|
299
|
+
packFailed: "An error occurred while packing API project"
|
|
300
|
+
}
|
|
301
|
+
}
|
|
302
|
+
};
|
|
303
|
+
// ../packager/packager-tool-apiworkflow/src/i18n/locales/zh-CN.json
|
|
304
|
+
var zh_CN_default = {
|
|
305
|
+
toolApiworkflow: {
|
|
306
|
+
info: {
|
|
307
|
+
restoreNotRequired: "Restore operation is not required for API projects",
|
|
308
|
+
validateNotRequired: "Validate operation is not required for API projects",
|
|
309
|
+
disposing: "Disposing API Workflows Tool"
|
|
310
|
+
},
|
|
311
|
+
progress: {
|
|
312
|
+
copyingFiles: "Copying files...",
|
|
313
|
+
creatingOperateFile: "Creating operate.json file...",
|
|
314
|
+
creatingPackageDescriptor: "Creating package-descriptor.json file...",
|
|
315
|
+
creatingNugetPackage: "Creating NuGet package...",
|
|
316
|
+
packageCreatedSuccessfully: "Package created successfully"
|
|
317
|
+
},
|
|
318
|
+
success: {
|
|
319
|
+
done: "done"
|
|
320
|
+
},
|
|
321
|
+
errors: {
|
|
322
|
+
buildFailed: "An error occurred while building API project files",
|
|
323
|
+
packFailed: "An error occurred while packing API project"
|
|
324
|
+
}
|
|
325
|
+
}
|
|
326
|
+
};
|
|
327
|
+
// ../packager/packager-tool-apiworkflow/src/i18n/locales/zh-TW.json
|
|
328
|
+
var zh_TW_default = {
|
|
329
|
+
toolApiworkflow: {
|
|
330
|
+
info: {
|
|
331
|
+
restoreNotRequired: "Restore operation is not required for API projects",
|
|
332
|
+
validateNotRequired: "Validate operation is not required for API projects",
|
|
333
|
+
disposing: "Disposing API Workflows Tool"
|
|
334
|
+
},
|
|
335
|
+
progress: {
|
|
336
|
+
copyingFiles: "Copying files...",
|
|
337
|
+
creatingOperateFile: "Creating operate.json file...",
|
|
338
|
+
creatingPackageDescriptor: "Creating package-descriptor.json file...",
|
|
339
|
+
creatingNugetPackage: "Creating NuGet package...",
|
|
340
|
+
packageCreatedSuccessfully: "Package created successfully"
|
|
341
|
+
},
|
|
342
|
+
success: {
|
|
343
|
+
done: "done"
|
|
344
|
+
},
|
|
345
|
+
errors: {
|
|
346
|
+
buildFailed: "An error occurred while building API project files",
|
|
347
|
+
packFailed: "An error occurred while packing API project"
|
|
348
|
+
}
|
|
349
|
+
}
|
|
350
|
+
};
|
|
351
|
+
// ../packager/packager-tool-apiworkflow/src/i18n/locales/zu.json
|
|
352
|
+
var zu_default = {
|
|
353
|
+
toolApiworkflow: {
|
|
354
|
+
info: {
|
|
355
|
+
restoreNotRequired: "Restore operation is not required for API projects",
|
|
356
|
+
validateNotRequired: "Validate operation is not required for API projects",
|
|
357
|
+
disposing: "Disposing API Workflows Tool"
|
|
358
|
+
},
|
|
359
|
+
progress: {
|
|
360
|
+
copyingFiles: "Copying files...",
|
|
361
|
+
creatingOperateFile: "Creating operate.json file...",
|
|
362
|
+
creatingPackageDescriptor: "Creating package-descriptor.json file...",
|
|
363
|
+
creatingNugetPackage: "Creating NuGet package...",
|
|
364
|
+
packageCreatedSuccessfully: "Package created successfully"
|
|
365
|
+
},
|
|
366
|
+
success: {
|
|
367
|
+
done: "done"
|
|
368
|
+
},
|
|
369
|
+
errors: {
|
|
370
|
+
buildFailed: "An error occurred while building API project files",
|
|
371
|
+
packFailed: "An error occurred while packing API project"
|
|
372
|
+
}
|
|
373
|
+
}
|
|
374
|
+
};
|
|
375
|
+
|
|
376
|
+
// ../packager/packager-tool-apiworkflow/src/i18n/index.ts
|
|
377
|
+
I18nManager.registerTranslations("en", en);
|
|
378
|
+
I18nManager.registerTranslations("de", de_default);
|
|
379
|
+
I18nManager.registerTranslations("es", es_default);
|
|
380
|
+
I18nManager.registerTranslations("es-MX", es_MX_default);
|
|
381
|
+
I18nManager.registerTranslations("fr", fr_default);
|
|
382
|
+
I18nManager.registerTranslations("ja", ja_default);
|
|
383
|
+
I18nManager.registerTranslations("ko", ko_default);
|
|
384
|
+
I18nManager.registerTranslations("pt", pt_default);
|
|
385
|
+
I18nManager.registerTranslations("pt-BR", pt_BR_default);
|
|
386
|
+
I18nManager.registerTranslations("ro", ro_default);
|
|
387
|
+
I18nManager.registerTranslations("ru", ru_default);
|
|
388
|
+
I18nManager.registerTranslations("tr", tr_default);
|
|
389
|
+
I18nManager.registerTranslations("zh-CN", zh_CN_default);
|
|
390
|
+
I18nManager.registerTranslations("zh-TW", zh_TW_default);
|
|
391
|
+
I18nManager.registerTranslations("zu", zu_default);
|
|
392
|
+
|
|
393
|
+
// ../packager/packager-tool-apiworkflow/src/api-workflows-tool.ts
|
|
394
|
+
class ApiWorkflowsTool extends ProjectTool {
|
|
395
|
+
_temporaryStorage;
|
|
396
|
+
constructor(fileSystem, logger) {
|
|
397
|
+
super(fileSystem, logger);
|
|
398
|
+
this._temporaryStorage = new TemporaryStorageService(fileSystem);
|
|
399
|
+
}
|
|
400
|
+
async restoreAsync(_options, _cancellationToken) {
|
|
401
|
+
this.logger.info(translate.t("toolApiworkflow.info.restoreNotRequired"));
|
|
402
|
+
return ToolResult.success();
|
|
403
|
+
}
|
|
404
|
+
async validateAsync(_options, _cancellationToken) {
|
|
405
|
+
this.logger.info(translate.t("toolApiworkflow.info.validateNotRequired"));
|
|
406
|
+
return ToolResult.success();
|
|
407
|
+
}
|
|
408
|
+
async buildAsync(options, _cancellationToken) {
|
|
409
|
+
const tempFolder = await this._temporaryStorage.getTempFolderPath();
|
|
410
|
+
const localBuildFolder = Path.join(tempFolder, NugetConstants.OutputFolderName);
|
|
411
|
+
const contentFolder = Path.join(localBuildFolder, NugetConstants.ContentFolderName);
|
|
412
|
+
try {
|
|
413
|
+
this.logger.progress(translate.t("toolApiworkflow.progress.copyingFiles"));
|
|
414
|
+
await this.copyFiles(options.projectPath, contentFolder);
|
|
415
|
+
this.logger.progress(translate.t("toolApiworkflow.progress.creatingOperateFile"));
|
|
416
|
+
await this.createOperateFile(options, contentFolder);
|
|
417
|
+
this.logger.progress(translate.t("toolApiworkflow.progress.creatingPackageDescriptor"));
|
|
418
|
+
await this.createPackageDescriptor(localBuildFolder);
|
|
419
|
+
return new ToolResult(ToolErrorCodes.Success, translate.t("toolApiworkflow.success.done"), [localBuildFolder]);
|
|
420
|
+
} catch (error) {
|
|
421
|
+
const errorMessage = error instanceof Error ? error.toString() : String(error);
|
|
422
|
+
this.logger.error(errorMessage);
|
|
423
|
+
return ToolResult.error(ToolErrorCodes.InternalError, translate.t("toolApiworkflow.errors.buildFailed"));
|
|
424
|
+
}
|
|
425
|
+
}
|
|
426
|
+
async packAsync(options, cancellationToken) {
|
|
427
|
+
const buildResult = await this.buildAsync(options, cancellationToken);
|
|
428
|
+
if (!buildResult.isSuccess) {
|
|
429
|
+
return buildResult;
|
|
430
|
+
}
|
|
431
|
+
const localBuildFolder = buildResult.packages[0];
|
|
432
|
+
try {
|
|
433
|
+
this.logger.progress(translate.t("toolApiworkflow.progress.creatingNugetPackage"));
|
|
434
|
+
const nupkgFileName = `${options.package.id}.${options.package.version}.nupkg`;
|
|
435
|
+
const nupkgPath = Path.join(options.outputPath, nupkgFileName);
|
|
436
|
+
const packager = new NugetPackager(this.fileSystem);
|
|
437
|
+
const result = await packager.packAsync(localBuildFolder, options.package, nupkgPath);
|
|
438
|
+
this.logger.progress(translate.t("toolApiworkflow.progress.packageCreatedSuccessfully"));
|
|
439
|
+
return new ToolResult(ToolErrorCodes.Success, translate.t("toolApiworkflow.success.done"), [result.outputPath]);
|
|
440
|
+
} catch (error) {
|
|
441
|
+
const errorMessage = error instanceof Error ? error.toString() : String(error);
|
|
442
|
+
this.logger.error(errorMessage);
|
|
443
|
+
return ToolResult.error(ToolErrorCodes.InternalError, translate.t("toolApiworkflow.errors.packFailed"));
|
|
444
|
+
}
|
|
445
|
+
}
|
|
446
|
+
async dispose() {
|
|
447
|
+
this.logger.info(translate.t("toolApiworkflow.info.disposing"));
|
|
448
|
+
try {
|
|
449
|
+
await this._temporaryStorage.cleanup();
|
|
450
|
+
} catch {}
|
|
451
|
+
}
|
|
452
|
+
async copyFiles(sourcePath, destinationPath) {
|
|
453
|
+
await this.fileSystem.mkdir(destinationPath);
|
|
454
|
+
const files = await this.fileSystem.readdir(sourcePath);
|
|
455
|
+
for (const file of files) {
|
|
456
|
+
const sourceFile = Path.join(sourcePath, file);
|
|
457
|
+
const destinationFile = Path.join(destinationPath, file);
|
|
458
|
+
const stat = await this.fileSystem.stat(sourceFile);
|
|
459
|
+
if (stat?.isFile()) {
|
|
460
|
+
const content = await this.fileSystem.readFile(sourceFile);
|
|
461
|
+
if (content) {
|
|
462
|
+
await this.fileSystem.writeFile(destinationFile, content);
|
|
463
|
+
}
|
|
464
|
+
}
|
|
465
|
+
}
|
|
466
|
+
}
|
|
467
|
+
async createOperateFile(options, contentFolder) {
|
|
468
|
+
await ensureContentOperateFile(this.fileSystem, {
|
|
469
|
+
contentFolder,
|
|
470
|
+
projectPath: options.projectPath,
|
|
471
|
+
projectStorageId: options.projectStorageId,
|
|
472
|
+
contentType: ProjectTypes.Api
|
|
473
|
+
});
|
|
474
|
+
}
|
|
475
|
+
async createPackageDescriptor(localBuildFolder) {
|
|
476
|
+
const packageDescriptor = {
|
|
477
|
+
files: {}
|
|
478
|
+
};
|
|
479
|
+
this.addFileIfExists(packageDescriptor, localBuildFolder, NugetConstants.OperateFileName, NugetConstants.OperateFileName);
|
|
480
|
+
this.addFileIfExists(packageDescriptor, localBuildFolder, NugetConstants.EntryPointsFileName, NugetConstants.EntryPointsFileName);
|
|
481
|
+
this.addFileIfExists(packageDescriptor, localBuildFolder, NugetConstants.BindingsFileId, NugetConstants.BindingsV2FileName);
|
|
482
|
+
const packageDescriptorPath = Path.join(localBuildFolder, NugetConstants.ContentFolderName, NugetConstants.PackageDescriptorFileName);
|
|
483
|
+
const packageDescriptorJson = JSON.stringify({
|
|
484
|
+
$schema: "https://cloud.uipath.com/draft/2024-12/package-descriptor",
|
|
485
|
+
...packageDescriptor
|
|
486
|
+
}, null, 2);
|
|
487
|
+
await this.fileSystem.writeFile(packageDescriptorPath, packageDescriptorJson);
|
|
488
|
+
}
|
|
489
|
+
addFileIfExists(packageDescriptor, _rootFolder, key, fileName) {
|
|
490
|
+
const relativePath = Path.join(NugetConstants.ContentFolderName, fileName);
|
|
491
|
+
packageDescriptor.files[key] = relativePath;
|
|
492
|
+
}
|
|
493
|
+
}
|
|
494
|
+
|
|
495
|
+
// ../packager/packager-tool-apiworkflow/src/api-workflow-tool-factory.ts
|
|
496
|
+
class ApiWorkflowToolFactory {
|
|
497
|
+
supportedTypes = [ProjectTypes.Api];
|
|
498
|
+
async createAsync(logger, fileSystem) {
|
|
499
|
+
return new ApiWorkflowsTool(fileSystem, logger);
|
|
500
|
+
}
|
|
501
|
+
}
|
|
502
|
+
// ../packager/packager-core/src/i18n/types.ts
|
|
503
|
+
function isPluralForm(value) {
|
|
504
|
+
return typeof value === "object" && value !== null && "other" in value;
|
|
505
|
+
}
|
|
506
|
+
function selectPluralForm(forms, count) {
|
|
507
|
+
if (count === 0 && forms.zero !== undefined) {
|
|
508
|
+
return forms.zero;
|
|
509
|
+
}
|
|
510
|
+
if (count === 1 && forms.one !== undefined) {
|
|
511
|
+
return forms.one;
|
|
512
|
+
}
|
|
513
|
+
if (count === 2 && forms.two !== undefined) {
|
|
514
|
+
return forms.two;
|
|
515
|
+
}
|
|
516
|
+
if (forms.few !== undefined) {
|
|
517
|
+
const mod10 = count % 10;
|
|
518
|
+
const mod100 = count % 100;
|
|
519
|
+
if (mod10 >= 2 && mod10 <= 4 && (mod100 < 10 || mod100 >= 20)) {
|
|
520
|
+
return forms.few;
|
|
521
|
+
}
|
|
522
|
+
}
|
|
523
|
+
if (forms.many !== undefined) {
|
|
524
|
+
const mod10 = count % 10;
|
|
525
|
+
const mod100 = count % 100;
|
|
526
|
+
if (count === 0 || mod10 === 0 && mod100 !== 0 || mod10 >= 5 && mod10 <= 9 || mod100 >= 11 && mod100 <= 14) {
|
|
527
|
+
return forms.many;
|
|
528
|
+
}
|
|
529
|
+
}
|
|
530
|
+
return forms.other;
|
|
531
|
+
}
|
|
532
|
+
|
|
533
|
+
// ../packager/packager-core/src/i18n/i18n-manager.ts
|
|
534
|
+
class I18nManager2 {
|
|
535
|
+
static translations = {};
|
|
536
|
+
static currentLocale = "en";
|
|
537
|
+
static fallbackLocale = "en";
|
|
538
|
+
static registerTranslations(locale, catalog) {
|
|
539
|
+
if (!I18nManager2.translations[locale]) {
|
|
540
|
+
I18nManager2.translations[locale] = {};
|
|
541
|
+
}
|
|
542
|
+
I18nManager2.translations[locale] = I18nManager2.deepMerge(I18nManager2.translations[locale], catalog);
|
|
543
|
+
}
|
|
544
|
+
static setLocale(locale) {
|
|
545
|
+
const normalized = I18nManager2.normalizeLocale(locale);
|
|
546
|
+
if (I18nManager2.translations[normalized]) {
|
|
547
|
+
I18nManager2.currentLocale = normalized;
|
|
548
|
+
return normalized;
|
|
549
|
+
}
|
|
550
|
+
const baseLocale = normalized.split("-")[0];
|
|
551
|
+
if (baseLocale !== normalized && I18nManager2.translations[baseLocale]) {
|
|
552
|
+
I18nManager2.currentLocale = baseLocale;
|
|
553
|
+
return baseLocale;
|
|
554
|
+
}
|
|
555
|
+
return I18nManager2.currentLocale;
|
|
556
|
+
}
|
|
557
|
+
static getLocale() {
|
|
558
|
+
return I18nManager2.currentLocale;
|
|
559
|
+
}
|
|
560
|
+
static setFallbackLocale(locale) {
|
|
561
|
+
I18nManager2.fallbackLocale = I18nManager2.normalizeLocale(locale);
|
|
562
|
+
}
|
|
563
|
+
static t(key, params, locale) {
|
|
564
|
+
const targetLocale = locale ? I18nManager2.normalizeLocale(locale) : I18nManager2.currentLocale;
|
|
565
|
+
let value = I18nManager2.getTranslationValue(key, targetLocale);
|
|
566
|
+
if (value === undefined && targetLocale !== I18nManager2.fallbackLocale) {
|
|
567
|
+
value = I18nManager2.getTranslationValue(key, I18nManager2.fallbackLocale);
|
|
568
|
+
}
|
|
569
|
+
if (value === undefined) {
|
|
570
|
+
return key;
|
|
571
|
+
}
|
|
572
|
+
if (isPluralForm(value) && params && "count" in params) {
|
|
573
|
+
const count = typeof params.count === "number" ? params.count : Number(params.count);
|
|
574
|
+
value = selectPluralForm(value, count);
|
|
575
|
+
} else if (isPluralForm(value)) {
|
|
576
|
+
value = value.other;
|
|
577
|
+
}
|
|
578
|
+
if (typeof value !== "string") {
|
|
579
|
+
return key;
|
|
580
|
+
}
|
|
581
|
+
return params ? I18nManager2.interpolate(value, params) : value;
|
|
582
|
+
}
|
|
583
|
+
static has(key, locale) {
|
|
584
|
+
const targetLocale = locale ? I18nManager2.normalizeLocale(locale) : I18nManager2.currentLocale;
|
|
585
|
+
const value = I18nManager2.getTranslationValue(key, targetLocale);
|
|
586
|
+
if (value !== undefined) {
|
|
587
|
+
return true;
|
|
588
|
+
}
|
|
589
|
+
if (targetLocale !== I18nManager2.fallbackLocale) {
|
|
590
|
+
return I18nManager2.getTranslationValue(key, I18nManager2.fallbackLocale) !== undefined;
|
|
591
|
+
}
|
|
592
|
+
return false;
|
|
593
|
+
}
|
|
594
|
+
static getAvailableLocales() {
|
|
595
|
+
return Object.keys(I18nManager2.translations);
|
|
596
|
+
}
|
|
597
|
+
static clearTranslations() {
|
|
598
|
+
I18nManager2.translations = {};
|
|
599
|
+
I18nManager2.currentLocale = "en";
|
|
600
|
+
}
|
|
601
|
+
static getTranslationValue(key, locale) {
|
|
602
|
+
const catalog = I18nManager2.translations[locale];
|
|
603
|
+
if (!catalog) {
|
|
604
|
+
return;
|
|
605
|
+
}
|
|
606
|
+
const keys = key.split(".");
|
|
607
|
+
let value = catalog;
|
|
608
|
+
for (const k of keys) {
|
|
609
|
+
if (value && typeof value === "object" && k in value) {
|
|
610
|
+
value = value[k];
|
|
611
|
+
} else {
|
|
612
|
+
return;
|
|
613
|
+
}
|
|
614
|
+
}
|
|
615
|
+
return value;
|
|
616
|
+
}
|
|
617
|
+
static interpolate(template, params) {
|
|
618
|
+
return template.replace(/\{(\w+)\}/g, (_, key) => {
|
|
619
|
+
const value = params[key];
|
|
620
|
+
return value !== undefined ? String(value) : `{${key}}`;
|
|
621
|
+
});
|
|
622
|
+
}
|
|
623
|
+
static normalizeLocale(locale) {
|
|
624
|
+
const normalized = locale.toLowerCase().replace(/_/g, "-");
|
|
625
|
+
const specialLocales = ["es-mx", "pt-br", "zh-cn", "zh-tw"];
|
|
626
|
+
if (specialLocales.includes(normalized)) {
|
|
627
|
+
return normalized;
|
|
628
|
+
}
|
|
629
|
+
return normalized.split("-")[0];
|
|
630
|
+
}
|
|
631
|
+
static deepMerge(target, source) {
|
|
632
|
+
const result = { ...target };
|
|
633
|
+
for (const key of Object.keys(source)) {
|
|
634
|
+
const sourceValue = source[key];
|
|
635
|
+
const targetValue = result[key];
|
|
636
|
+
if (sourceValue && typeof sourceValue === "object" && !Array.isArray(sourceValue) && targetValue && typeof targetValue === "object" && !Array.isArray(targetValue)) {
|
|
637
|
+
result[key] = I18nManager2.deepMerge(targetValue, sourceValue);
|
|
638
|
+
} else {
|
|
639
|
+
result[key] = sourceValue;
|
|
640
|
+
}
|
|
641
|
+
}
|
|
642
|
+
return result;
|
|
643
|
+
}
|
|
644
|
+
}
|
|
645
|
+
|
|
646
|
+
// ../packager/packager-core/src/i18n/locales/de.ts
|
|
647
|
+
var de = {
|
|
648
|
+
toolCore: {
|
|
649
|
+
errors: {
|
|
650
|
+
internal: "Internal error: {message}",
|
|
651
|
+
fileNotFound: "File not found: {path}",
|
|
652
|
+
fileReadFailed: "Failed to read file: {path}",
|
|
653
|
+
fileWriteFailed: "Failed to write file: {path}",
|
|
654
|
+
directoryNotFound: "Directory not found: {path}",
|
|
655
|
+
invalidPath: "{path} is not a valid path",
|
|
656
|
+
operationCanceled: "Operation was canceled",
|
|
657
|
+
invalidParameter: "Invalid parameter: {parameter}"
|
|
658
|
+
},
|
|
659
|
+
progress: {
|
|
660
|
+
copying: "Copying files...",
|
|
661
|
+
building: "Building project...",
|
|
662
|
+
packaging: "Creating package...",
|
|
663
|
+
validating: "Validating...",
|
|
664
|
+
analyzing: "Analyzing...",
|
|
665
|
+
restoring: "Restoring dependencies..."
|
|
666
|
+
},
|
|
667
|
+
validation: {
|
|
668
|
+
requiredField: "{field} is required",
|
|
669
|
+
invalidValue: "Invalid value for {field}",
|
|
670
|
+
pathNotFound: "Path not found: {path}",
|
|
671
|
+
fileRequired: "File is required: {path}",
|
|
672
|
+
directoryRequired: "Directory is required: {path}"
|
|
673
|
+
},
|
|
674
|
+
warnings: {
|
|
675
|
+
factoryAlreadyRegistered: "A factory is already registered for project type '{type}'. Skipping duplicate registration."
|
|
676
|
+
},
|
|
677
|
+
info: {
|
|
678
|
+
operationComplete: "Operation completed successfully",
|
|
679
|
+
filesProcessed: {
|
|
680
|
+
zero: "No files processed",
|
|
681
|
+
one: "{count} file processed",
|
|
682
|
+
other: "{count} files processed"
|
|
683
|
+
}
|
|
684
|
+
}
|
|
685
|
+
}
|
|
686
|
+
};
|
|
687
|
+
|
|
688
|
+
// ../packager/packager-core/src/i18n/locales/en.ts
|
|
689
|
+
var en2 = {
|
|
690
|
+
toolCore: {
|
|
691
|
+
errors: {
|
|
692
|
+
internal: "Internal error: {message}",
|
|
693
|
+
fileNotFound: "File not found: {path}",
|
|
694
|
+
fileReadFailed: "Failed to read file: {path}",
|
|
695
|
+
fileWriteFailed: "Failed to write file: {path}",
|
|
696
|
+
directoryNotFound: "Directory not found: {path}",
|
|
697
|
+
invalidPath: "{path} is not a valid path",
|
|
698
|
+
operationCanceled: "Operation was canceled",
|
|
699
|
+
invalidParameter: "Invalid parameter: {parameter}"
|
|
700
|
+
},
|
|
701
|
+
progress: {
|
|
702
|
+
copying: "Copying files...",
|
|
703
|
+
building: "Building project...",
|
|
704
|
+
packaging: "Creating package...",
|
|
705
|
+
validating: "Validating...",
|
|
706
|
+
analyzing: "Analyzing...",
|
|
707
|
+
restoring: "Restoring dependencies..."
|
|
708
|
+
},
|
|
709
|
+
validation: {
|
|
710
|
+
requiredField: "{field} is required",
|
|
711
|
+
invalidValue: "Invalid value for {field}",
|
|
712
|
+
pathNotFound: "Path not found: {path}",
|
|
713
|
+
fileRequired: "File is required: {path}",
|
|
714
|
+
directoryRequired: "Directory is required: {path}"
|
|
715
|
+
},
|
|
716
|
+
warnings: {
|
|
717
|
+
factoryAlreadyRegistered: "A factory is already registered for project type '{type}'. Skipping duplicate registration."
|
|
718
|
+
},
|
|
719
|
+
info: {
|
|
720
|
+
operationComplete: "Operation completed successfully",
|
|
721
|
+
filesProcessed: {
|
|
722
|
+
zero: "No files processed",
|
|
723
|
+
one: "{count} file processed",
|
|
724
|
+
other: "{count} files processed"
|
|
725
|
+
}
|
|
726
|
+
}
|
|
727
|
+
}
|
|
728
|
+
};
|
|
729
|
+
|
|
730
|
+
// ../packager/packager-core/src/i18n/locales/es.ts
|
|
731
|
+
var es = {
|
|
732
|
+
toolCore: {
|
|
733
|
+
errors: {
|
|
734
|
+
internal: "Internal error: {message}",
|
|
735
|
+
fileNotFound: "File not found: {path}",
|
|
736
|
+
fileReadFailed: "Failed to read file: {path}",
|
|
737
|
+
fileWriteFailed: "Failed to write file: {path}",
|
|
738
|
+
directoryNotFound: "Directory not found: {path}",
|
|
739
|
+
invalidPath: "{path} is not a valid path",
|
|
740
|
+
operationCanceled: "Operation was canceled",
|
|
741
|
+
invalidParameter: "Invalid parameter: {parameter}"
|
|
742
|
+
},
|
|
743
|
+
progress: {
|
|
744
|
+
copying: "Copying files...",
|
|
745
|
+
building: "Building project...",
|
|
746
|
+
packaging: "Creating package...",
|
|
747
|
+
validating: "Validating...",
|
|
748
|
+
analyzing: "Analyzing...",
|
|
749
|
+
restoring: "Restoring dependencies..."
|
|
750
|
+
},
|
|
751
|
+
validation: {
|
|
752
|
+
requiredField: "{field} is required",
|
|
753
|
+
invalidValue: "Invalid value for {field}",
|
|
754
|
+
pathNotFound: "Path not found: {path}",
|
|
755
|
+
fileRequired: "File is required: {path}",
|
|
756
|
+
directoryRequired: "Directory is required: {path}"
|
|
757
|
+
},
|
|
758
|
+
warnings: {
|
|
759
|
+
factoryAlreadyRegistered: "A factory is already registered for project type '{type}'. Skipping duplicate registration."
|
|
760
|
+
},
|
|
761
|
+
info: {
|
|
762
|
+
operationComplete: "Operation completed successfully",
|
|
763
|
+
filesProcessed: {
|
|
764
|
+
zero: "No files processed",
|
|
765
|
+
one: "{count} file processed",
|
|
766
|
+
other: "{count} files processed"
|
|
767
|
+
}
|
|
768
|
+
}
|
|
769
|
+
}
|
|
770
|
+
};
|
|
771
|
+
|
|
772
|
+
// ../packager/packager-core/src/i18n/locales/es-MX.ts
|
|
773
|
+
var es_MX = {
|
|
774
|
+
toolCore: {
|
|
775
|
+
errors: {
|
|
776
|
+
internal: "Internal error: {message}",
|
|
777
|
+
fileNotFound: "File not found: {path}",
|
|
778
|
+
fileReadFailed: "Failed to read file: {path}",
|
|
779
|
+
fileWriteFailed: "Failed to write file: {path}",
|
|
780
|
+
directoryNotFound: "Directory not found: {path}",
|
|
781
|
+
invalidPath: "{path} is not a valid path",
|
|
782
|
+
operationCanceled: "Operation was canceled",
|
|
783
|
+
invalidParameter: "Invalid parameter: {parameter}"
|
|
784
|
+
},
|
|
785
|
+
progress: {
|
|
786
|
+
copying: "Copying files...",
|
|
787
|
+
building: "Building project...",
|
|
788
|
+
packaging: "Creating package...",
|
|
789
|
+
validating: "Validating...",
|
|
790
|
+
analyzing: "Analyzing...",
|
|
791
|
+
restoring: "Restoring dependencies..."
|
|
792
|
+
},
|
|
793
|
+
validation: {
|
|
794
|
+
requiredField: "{field} is required",
|
|
795
|
+
invalidValue: "Invalid value for {field}",
|
|
796
|
+
pathNotFound: "Path not found: {path}",
|
|
797
|
+
fileRequired: "File is required: {path}",
|
|
798
|
+
directoryRequired: "Directory is required: {path}"
|
|
799
|
+
},
|
|
800
|
+
warnings: {
|
|
801
|
+
factoryAlreadyRegistered: "A factory is already registered for project type '{type}'. Skipping duplicate registration."
|
|
802
|
+
},
|
|
803
|
+
info: {
|
|
804
|
+
operationComplete: "Operation completed successfully",
|
|
805
|
+
filesProcessed: {
|
|
806
|
+
zero: "No files processed",
|
|
807
|
+
one: "{count} file processed",
|
|
808
|
+
other: "{count} files processed"
|
|
809
|
+
}
|
|
810
|
+
}
|
|
811
|
+
}
|
|
812
|
+
};
|
|
813
|
+
|
|
814
|
+
// ../packager/packager-core/src/i18n/locales/fr.ts
|
|
815
|
+
var fr = {
|
|
816
|
+
toolCore: {
|
|
817
|
+
errors: {
|
|
818
|
+
internal: "Internal error: {message}",
|
|
819
|
+
fileNotFound: "File not found: {path}",
|
|
820
|
+
fileReadFailed: "Failed to read file: {path}",
|
|
821
|
+
fileWriteFailed: "Failed to write file: {path}",
|
|
822
|
+
directoryNotFound: "Directory not found: {path}",
|
|
823
|
+
invalidPath: "{path} is not a valid path",
|
|
824
|
+
operationCanceled: "Operation was canceled",
|
|
825
|
+
invalidParameter: "Invalid parameter: {parameter}"
|
|
826
|
+
},
|
|
827
|
+
progress: {
|
|
828
|
+
copying: "Copying files...",
|
|
829
|
+
building: "Building project...",
|
|
830
|
+
packaging: "Creating package...",
|
|
831
|
+
validating: "Validating...",
|
|
832
|
+
analyzing: "Analyzing...",
|
|
833
|
+
restoring: "Restoring dependencies..."
|
|
834
|
+
},
|
|
835
|
+
validation: {
|
|
836
|
+
requiredField: "{field} is required",
|
|
837
|
+
invalidValue: "Invalid value for {field}",
|
|
838
|
+
pathNotFound: "Path not found: {path}",
|
|
839
|
+
fileRequired: "File is required: {path}",
|
|
840
|
+
directoryRequired: "Directory is required: {path}"
|
|
841
|
+
},
|
|
842
|
+
warnings: {
|
|
843
|
+
factoryAlreadyRegistered: "A factory is already registered for project type '{type}'. Skipping duplicate registration."
|
|
844
|
+
},
|
|
845
|
+
info: {
|
|
846
|
+
operationComplete: "Operation completed successfully",
|
|
847
|
+
filesProcessed: {
|
|
848
|
+
zero: "No files processed",
|
|
849
|
+
one: "{count} file processed",
|
|
850
|
+
other: "{count} files processed"
|
|
851
|
+
}
|
|
852
|
+
}
|
|
853
|
+
}
|
|
854
|
+
};
|
|
855
|
+
|
|
856
|
+
// ../packager/packager-core/src/i18n/locales/ja.ts
|
|
857
|
+
var ja = {
|
|
858
|
+
toolCore: {
|
|
859
|
+
errors: {
|
|
860
|
+
internal: "Internal error: {message}",
|
|
861
|
+
fileNotFound: "File not found: {path}",
|
|
862
|
+
fileReadFailed: "Failed to read file: {path}",
|
|
863
|
+
fileWriteFailed: "Failed to write file: {path}",
|
|
864
|
+
directoryNotFound: "Directory not found: {path}",
|
|
865
|
+
invalidPath: "{path} is not a valid path",
|
|
866
|
+
operationCanceled: "Operation was canceled",
|
|
867
|
+
invalidParameter: "Invalid parameter: {parameter}"
|
|
868
|
+
},
|
|
869
|
+
progress: {
|
|
870
|
+
copying: "Copying files...",
|
|
871
|
+
building: "Building project...",
|
|
872
|
+
packaging: "Creating package...",
|
|
873
|
+
validating: "Validating...",
|
|
874
|
+
analyzing: "Analyzing...",
|
|
875
|
+
restoring: "Restoring dependencies..."
|
|
876
|
+
},
|
|
877
|
+
validation: {
|
|
878
|
+
requiredField: "{field} is required",
|
|
879
|
+
invalidValue: "Invalid value for {field}",
|
|
880
|
+
pathNotFound: "Path not found: {path}",
|
|
881
|
+
fileRequired: "File is required: {path}",
|
|
882
|
+
directoryRequired: "Directory is required: {path}"
|
|
883
|
+
},
|
|
884
|
+
warnings: {
|
|
885
|
+
factoryAlreadyRegistered: "A factory is already registered for project type '{type}'. Skipping duplicate registration."
|
|
886
|
+
},
|
|
887
|
+
info: {
|
|
888
|
+
operationComplete: "Operation completed successfully",
|
|
889
|
+
filesProcessed: {
|
|
890
|
+
zero: "No files processed",
|
|
891
|
+
one: "{count} file processed",
|
|
892
|
+
other: "{count} files processed"
|
|
893
|
+
}
|
|
894
|
+
}
|
|
895
|
+
}
|
|
896
|
+
};
|
|
897
|
+
|
|
898
|
+
// ../packager/packager-core/src/i18n/locales/ko.ts
|
|
899
|
+
var ko = {
|
|
900
|
+
toolCore: {
|
|
901
|
+
errors: {
|
|
902
|
+
internal: "Internal error: {message}",
|
|
903
|
+
fileNotFound: "File not found: {path}",
|
|
904
|
+
fileReadFailed: "Failed to read file: {path}",
|
|
905
|
+
fileWriteFailed: "Failed to write file: {path}",
|
|
906
|
+
directoryNotFound: "Directory not found: {path}",
|
|
907
|
+
invalidPath: "{path} is not a valid path",
|
|
908
|
+
operationCanceled: "Operation was canceled",
|
|
909
|
+
invalidParameter: "Invalid parameter: {parameter}"
|
|
910
|
+
},
|
|
911
|
+
progress: {
|
|
912
|
+
copying: "Copying files...",
|
|
913
|
+
building: "Building project...",
|
|
914
|
+
packaging: "Creating package...",
|
|
915
|
+
validating: "Validating...",
|
|
916
|
+
analyzing: "Analyzing...",
|
|
917
|
+
restoring: "Restoring dependencies..."
|
|
918
|
+
},
|
|
919
|
+
validation: {
|
|
920
|
+
requiredField: "{field} is required",
|
|
921
|
+
invalidValue: "Invalid value for {field}",
|
|
922
|
+
pathNotFound: "Path not found: {path}",
|
|
923
|
+
fileRequired: "File is required: {path}",
|
|
924
|
+
directoryRequired: "Directory is required: {path}"
|
|
925
|
+
},
|
|
926
|
+
warnings: {
|
|
927
|
+
factoryAlreadyRegistered: "A factory is already registered for project type '{type}'. Skipping duplicate registration."
|
|
928
|
+
},
|
|
929
|
+
info: {
|
|
930
|
+
operationComplete: "Operation completed successfully",
|
|
931
|
+
filesProcessed: {
|
|
932
|
+
zero: "No files processed",
|
|
933
|
+
one: "{count} file processed",
|
|
934
|
+
other: "{count} files processed"
|
|
935
|
+
}
|
|
936
|
+
}
|
|
937
|
+
}
|
|
938
|
+
};
|
|
939
|
+
|
|
940
|
+
// ../packager/packager-core/src/i18n/locales/pt.ts
|
|
941
|
+
var pt = {
|
|
942
|
+
toolCore: {
|
|
943
|
+
errors: {
|
|
944
|
+
internal: "Internal error: {message}",
|
|
945
|
+
fileNotFound: "File not found: {path}",
|
|
946
|
+
fileReadFailed: "Failed to read file: {path}",
|
|
947
|
+
fileWriteFailed: "Failed to write file: {path}",
|
|
948
|
+
directoryNotFound: "Directory not found: {path}",
|
|
949
|
+
invalidPath: "{path} is not a valid path",
|
|
950
|
+
operationCanceled: "Operation was canceled",
|
|
951
|
+
invalidParameter: "Invalid parameter: {parameter}"
|
|
952
|
+
},
|
|
953
|
+
progress: {
|
|
954
|
+
copying: "Copying files...",
|
|
955
|
+
building: "Building project...",
|
|
956
|
+
packaging: "Creating package...",
|
|
957
|
+
validating: "Validating...",
|
|
958
|
+
analyzing: "Analyzing...",
|
|
959
|
+
restoring: "Restoring dependencies..."
|
|
960
|
+
},
|
|
961
|
+
validation: {
|
|
962
|
+
requiredField: "{field} is required",
|
|
963
|
+
invalidValue: "Invalid value for {field}",
|
|
964
|
+
pathNotFound: "Path not found: {path}",
|
|
965
|
+
fileRequired: "File is required: {path}",
|
|
966
|
+
directoryRequired: "Directory is required: {path}"
|
|
967
|
+
},
|
|
968
|
+
warnings: {
|
|
969
|
+
factoryAlreadyRegistered: "A factory is already registered for project type '{type}'. Skipping duplicate registration."
|
|
970
|
+
},
|
|
971
|
+
info: {
|
|
972
|
+
operationComplete: "Operation completed successfully",
|
|
973
|
+
filesProcessed: {
|
|
974
|
+
zero: "No files processed",
|
|
975
|
+
one: "{count} file processed",
|
|
976
|
+
other: "{count} files processed"
|
|
977
|
+
}
|
|
978
|
+
}
|
|
979
|
+
}
|
|
980
|
+
};
|
|
981
|
+
|
|
982
|
+
// ../packager/packager-core/src/i18n/locales/pt-BR.ts
|
|
983
|
+
var pt_BR = {
|
|
984
|
+
toolCore: {
|
|
985
|
+
errors: {
|
|
986
|
+
internal: "Internal error: {message}",
|
|
987
|
+
fileNotFound: "File not found: {path}",
|
|
988
|
+
fileReadFailed: "Failed to read file: {path}",
|
|
989
|
+
fileWriteFailed: "Failed to write file: {path}",
|
|
990
|
+
directoryNotFound: "Directory not found: {path}",
|
|
991
|
+
invalidPath: "{path} is not a valid path",
|
|
992
|
+
operationCanceled: "Operation was canceled",
|
|
993
|
+
invalidParameter: "Invalid parameter: {parameter}"
|
|
994
|
+
},
|
|
995
|
+
progress: {
|
|
996
|
+
copying: "Copying files...",
|
|
997
|
+
building: "Building project...",
|
|
998
|
+
packaging: "Creating package...",
|
|
999
|
+
validating: "Validating...",
|
|
1000
|
+
analyzing: "Analyzing...",
|
|
1001
|
+
restoring: "Restoring dependencies..."
|
|
1002
|
+
},
|
|
1003
|
+
validation: {
|
|
1004
|
+
requiredField: "{field} is required",
|
|
1005
|
+
invalidValue: "Invalid value for {field}",
|
|
1006
|
+
pathNotFound: "Path not found: {path}",
|
|
1007
|
+
fileRequired: "File is required: {path}",
|
|
1008
|
+
directoryRequired: "Directory is required: {path}"
|
|
1009
|
+
},
|
|
1010
|
+
warnings: {
|
|
1011
|
+
factoryAlreadyRegistered: "A factory is already registered for project type '{type}'. Skipping duplicate registration."
|
|
1012
|
+
},
|
|
1013
|
+
info: {
|
|
1014
|
+
operationComplete: "Operation completed successfully",
|
|
1015
|
+
filesProcessed: {
|
|
1016
|
+
zero: "No files processed",
|
|
1017
|
+
one: "{count} file processed",
|
|
1018
|
+
other: "{count} files processed"
|
|
1019
|
+
}
|
|
1020
|
+
}
|
|
1021
|
+
}
|
|
1022
|
+
};
|
|
1023
|
+
|
|
1024
|
+
// ../packager/packager-core/src/i18n/locales/ro.ts
|
|
1025
|
+
var ro = {
|
|
1026
|
+
toolCore: {
|
|
1027
|
+
errors: {
|
|
1028
|
+
internal: "Internal error: {message}",
|
|
1029
|
+
fileNotFound: "File not found: {path}",
|
|
1030
|
+
fileReadFailed: "Failed to read file: {path}",
|
|
1031
|
+
fileWriteFailed: "Failed to write file: {path}",
|
|
1032
|
+
directoryNotFound: "Directory not found: {path}",
|
|
1033
|
+
invalidPath: "{path} is not a valid path",
|
|
1034
|
+
operationCanceled: "Operation was canceled",
|
|
1035
|
+
invalidParameter: "Invalid parameter: {parameter}"
|
|
1036
|
+
},
|
|
1037
|
+
progress: {
|
|
1038
|
+
copying: "Copying files...",
|
|
1039
|
+
building: "Building project...",
|
|
1040
|
+
packaging: "Creating package...",
|
|
1041
|
+
validating: "Validating...",
|
|
1042
|
+
analyzing: "Analyzing...",
|
|
1043
|
+
restoring: "Restoring dependencies..."
|
|
1044
|
+
},
|
|
1045
|
+
validation: {
|
|
1046
|
+
requiredField: "{field} is required",
|
|
1047
|
+
invalidValue: "Invalid value for {field}",
|
|
1048
|
+
pathNotFound: "Path not found: {path}",
|
|
1049
|
+
fileRequired: "File is required: {path}",
|
|
1050
|
+
directoryRequired: "Directory is required: {path}"
|
|
1051
|
+
},
|
|
1052
|
+
warnings: {
|
|
1053
|
+
factoryAlreadyRegistered: "A factory is already registered for project type '{type}'. Skipping duplicate registration."
|
|
1054
|
+
},
|
|
1055
|
+
info: {
|
|
1056
|
+
operationComplete: "Operation completed successfully",
|
|
1057
|
+
filesProcessed: {
|
|
1058
|
+
zero: "No files processed",
|
|
1059
|
+
one: "{count} file processed",
|
|
1060
|
+
other: "{count} files processed"
|
|
1061
|
+
}
|
|
1062
|
+
}
|
|
1063
|
+
}
|
|
1064
|
+
};
|
|
1065
|
+
|
|
1066
|
+
// ../packager/packager-core/src/i18n/locales/ru.ts
|
|
1067
|
+
var ru = {
|
|
1068
|
+
toolCore: {
|
|
1069
|
+
errors: {
|
|
1070
|
+
internal: "Internal error: {message}",
|
|
1071
|
+
fileNotFound: "File not found: {path}",
|
|
1072
|
+
fileReadFailed: "Failed to read file: {path}",
|
|
1073
|
+
fileWriteFailed: "Failed to write file: {path}",
|
|
1074
|
+
directoryNotFound: "Directory not found: {path}",
|
|
1075
|
+
invalidPath: "{path} is not a valid path",
|
|
1076
|
+
operationCanceled: "Operation was canceled",
|
|
1077
|
+
invalidParameter: "Invalid parameter: {parameter}"
|
|
1078
|
+
},
|
|
1079
|
+
progress: {
|
|
1080
|
+
copying: "Copying files...",
|
|
1081
|
+
building: "Building project...",
|
|
1082
|
+
packaging: "Creating package...",
|
|
1083
|
+
validating: "Validating...",
|
|
1084
|
+
analyzing: "Analyzing...",
|
|
1085
|
+
restoring: "Restoring dependencies..."
|
|
1086
|
+
},
|
|
1087
|
+
validation: {
|
|
1088
|
+
requiredField: "{field} is required",
|
|
1089
|
+
invalidValue: "Invalid value for {field}",
|
|
1090
|
+
pathNotFound: "Path not found: {path}",
|
|
1091
|
+
fileRequired: "File is required: {path}",
|
|
1092
|
+
directoryRequired: "Directory is required: {path}"
|
|
1093
|
+
},
|
|
1094
|
+
warnings: {
|
|
1095
|
+
factoryAlreadyRegistered: "A factory is already registered for project type '{type}'. Skipping duplicate registration."
|
|
1096
|
+
},
|
|
1097
|
+
info: {
|
|
1098
|
+
operationComplete: "Operation completed successfully",
|
|
1099
|
+
filesProcessed: {
|
|
1100
|
+
zero: "No files processed",
|
|
1101
|
+
one: "{count} file processed",
|
|
1102
|
+
other: "{count} files processed"
|
|
1103
|
+
}
|
|
1104
|
+
}
|
|
1105
|
+
}
|
|
1106
|
+
};
|
|
1107
|
+
|
|
1108
|
+
// ../packager/packager-core/src/i18n/locales/tr.ts
|
|
1109
|
+
var tr = {
|
|
1110
|
+
toolCore: {
|
|
1111
|
+
errors: {
|
|
1112
|
+
internal: "Internal error: {message}",
|
|
1113
|
+
fileNotFound: "File not found: {path}",
|
|
1114
|
+
fileReadFailed: "Failed to read file: {path}",
|
|
1115
|
+
fileWriteFailed: "Failed to write file: {path}",
|
|
1116
|
+
directoryNotFound: "Directory not found: {path}",
|
|
1117
|
+
invalidPath: "{path} is not a valid path",
|
|
1118
|
+
operationCanceled: "Operation was canceled",
|
|
1119
|
+
invalidParameter: "Invalid parameter: {parameter}"
|
|
1120
|
+
},
|
|
1121
|
+
progress: {
|
|
1122
|
+
copying: "Copying files...",
|
|
1123
|
+
building: "Building project...",
|
|
1124
|
+
packaging: "Creating package...",
|
|
1125
|
+
validating: "Validating...",
|
|
1126
|
+
analyzing: "Analyzing...",
|
|
1127
|
+
restoring: "Restoring dependencies..."
|
|
1128
|
+
},
|
|
1129
|
+
validation: {
|
|
1130
|
+
requiredField: "{field} is required",
|
|
1131
|
+
invalidValue: "Invalid value for {field}",
|
|
1132
|
+
pathNotFound: "Path not found: {path}",
|
|
1133
|
+
fileRequired: "File is required: {path}",
|
|
1134
|
+
directoryRequired: "Directory is required: {path}"
|
|
1135
|
+
},
|
|
1136
|
+
warnings: {
|
|
1137
|
+
factoryAlreadyRegistered: "A factory is already registered for project type '{type}'. Skipping duplicate registration."
|
|
1138
|
+
},
|
|
1139
|
+
info: {
|
|
1140
|
+
operationComplete: "Operation completed successfully",
|
|
1141
|
+
filesProcessed: {
|
|
1142
|
+
zero: "No files processed",
|
|
1143
|
+
one: "{count} file processed",
|
|
1144
|
+
other: "{count} files processed"
|
|
1145
|
+
}
|
|
1146
|
+
}
|
|
1147
|
+
}
|
|
1148
|
+
};
|
|
1149
|
+
|
|
1150
|
+
// ../packager/packager-core/src/i18n/locales/zh-CN.ts
|
|
1151
|
+
var zh_CN = {
|
|
1152
|
+
toolCore: {
|
|
1153
|
+
errors: {
|
|
1154
|
+
internal: "Internal error: {message}",
|
|
1155
|
+
fileNotFound: "File not found: {path}",
|
|
1156
|
+
fileReadFailed: "Failed to read file: {path}",
|
|
1157
|
+
fileWriteFailed: "Failed to write file: {path}",
|
|
1158
|
+
directoryNotFound: "Directory not found: {path}",
|
|
1159
|
+
invalidPath: "{path} is not a valid path",
|
|
1160
|
+
operationCanceled: "Operation was canceled",
|
|
1161
|
+
invalidParameter: "Invalid parameter: {parameter}"
|
|
1162
|
+
},
|
|
1163
|
+
progress: {
|
|
1164
|
+
copying: "Copying files...",
|
|
1165
|
+
building: "Building project...",
|
|
1166
|
+
packaging: "Creating package...",
|
|
1167
|
+
validating: "Validating...",
|
|
1168
|
+
analyzing: "Analyzing...",
|
|
1169
|
+
restoring: "Restoring dependencies..."
|
|
1170
|
+
},
|
|
1171
|
+
validation: {
|
|
1172
|
+
requiredField: "{field} is required",
|
|
1173
|
+
invalidValue: "Invalid value for {field}",
|
|
1174
|
+
pathNotFound: "Path not found: {path}",
|
|
1175
|
+
fileRequired: "File is required: {path}",
|
|
1176
|
+
directoryRequired: "Directory is required: {path}"
|
|
1177
|
+
},
|
|
1178
|
+
warnings: {
|
|
1179
|
+
factoryAlreadyRegistered: "A factory is already registered for project type '{type}'. Skipping duplicate registration."
|
|
1180
|
+
},
|
|
1181
|
+
info: {
|
|
1182
|
+
operationComplete: "Operation completed successfully",
|
|
1183
|
+
filesProcessed: {
|
|
1184
|
+
zero: "No files processed",
|
|
1185
|
+
one: "{count} file processed",
|
|
1186
|
+
other: "{count} files processed"
|
|
1187
|
+
}
|
|
1188
|
+
}
|
|
1189
|
+
}
|
|
1190
|
+
};
|
|
1191
|
+
|
|
1192
|
+
// ../packager/packager-core/src/i18n/locales/zh-TW.ts
|
|
1193
|
+
var zh_TW = {
|
|
1194
|
+
toolCore: {
|
|
1195
|
+
errors: {
|
|
1196
|
+
internal: "Internal error: {message}",
|
|
1197
|
+
fileNotFound: "File not found: {path}",
|
|
1198
|
+
fileReadFailed: "Failed to read file: {path}",
|
|
1199
|
+
fileWriteFailed: "Failed to write file: {path}",
|
|
1200
|
+
directoryNotFound: "Directory not found: {path}",
|
|
1201
|
+
invalidPath: "{path} is not a valid path",
|
|
1202
|
+
operationCanceled: "Operation was canceled",
|
|
1203
|
+
invalidParameter: "Invalid parameter: {parameter}"
|
|
1204
|
+
},
|
|
1205
|
+
progress: {
|
|
1206
|
+
copying: "Copying files...",
|
|
1207
|
+
building: "Building project...",
|
|
1208
|
+
packaging: "Creating package...",
|
|
1209
|
+
validating: "Validating...",
|
|
1210
|
+
analyzing: "Analyzing...",
|
|
1211
|
+
restoring: "Restoring dependencies..."
|
|
1212
|
+
},
|
|
1213
|
+
validation: {
|
|
1214
|
+
requiredField: "{field} is required",
|
|
1215
|
+
invalidValue: "Invalid value for {field}",
|
|
1216
|
+
pathNotFound: "Path not found: {path}",
|
|
1217
|
+
fileRequired: "File is required: {path}",
|
|
1218
|
+
directoryRequired: "Directory is required: {path}"
|
|
1219
|
+
},
|
|
1220
|
+
warnings: {
|
|
1221
|
+
factoryAlreadyRegistered: "A factory is already registered for project type '{type}'. Skipping duplicate registration."
|
|
1222
|
+
},
|
|
1223
|
+
info: {
|
|
1224
|
+
operationComplete: "Operation completed successfully",
|
|
1225
|
+
filesProcessed: {
|
|
1226
|
+
zero: "No files processed",
|
|
1227
|
+
one: "{count} file processed",
|
|
1228
|
+
other: "{count} files processed"
|
|
1229
|
+
}
|
|
1230
|
+
}
|
|
1231
|
+
}
|
|
1232
|
+
};
|
|
1233
|
+
|
|
1234
|
+
// ../packager/packager-core/src/i18n/locales/zu.ts
|
|
1235
|
+
var zu = {
|
|
1236
|
+
toolCore: {
|
|
1237
|
+
errors: {
|
|
1238
|
+
internal: "Internal error: {message}",
|
|
1239
|
+
fileNotFound: "File not found: {path}",
|
|
1240
|
+
fileReadFailed: "Failed to read file: {path}",
|
|
1241
|
+
fileWriteFailed: "Failed to write file: {path}",
|
|
1242
|
+
directoryNotFound: "Directory not found: {path}",
|
|
1243
|
+
invalidPath: "{path} is not a valid path",
|
|
1244
|
+
operationCanceled: "Operation was canceled",
|
|
1245
|
+
invalidParameter: "Invalid parameter: {parameter}"
|
|
1246
|
+
},
|
|
1247
|
+
progress: {
|
|
1248
|
+
copying: "Copying files...",
|
|
1249
|
+
building: "Building project...",
|
|
1250
|
+
packaging: "Creating package...",
|
|
1251
|
+
validating: "Validating...",
|
|
1252
|
+
analyzing: "Analyzing...",
|
|
1253
|
+
restoring: "Restoring dependencies..."
|
|
1254
|
+
},
|
|
1255
|
+
validation: {
|
|
1256
|
+
requiredField: "{field} is required",
|
|
1257
|
+
invalidValue: "Invalid value for {field}",
|
|
1258
|
+
pathNotFound: "Path not found: {path}",
|
|
1259
|
+
fileRequired: "File is required: {path}",
|
|
1260
|
+
directoryRequired: "Directory is required: {path}"
|
|
1261
|
+
},
|
|
1262
|
+
warnings: {
|
|
1263
|
+
factoryAlreadyRegistered: "A factory is already registered for project type '{type}'. Skipping duplicate registration."
|
|
1264
|
+
},
|
|
1265
|
+
info: {
|
|
1266
|
+
operationComplete: "Operation completed successfully",
|
|
1267
|
+
filesProcessed: {
|
|
1268
|
+
zero: "No files processed",
|
|
1269
|
+
one: "{count} file processed",
|
|
1270
|
+
other: "{count} files processed"
|
|
1271
|
+
}
|
|
1272
|
+
}
|
|
1273
|
+
}
|
|
1274
|
+
};
|
|
1275
|
+
|
|
1276
|
+
// ../packager/packager-core/src/i18n/translation-service.ts
|
|
1277
|
+
class TranslationService {
|
|
1278
|
+
static instance;
|
|
1279
|
+
currentLocale = "en";
|
|
1280
|
+
constructor() {}
|
|
1281
|
+
static getInstance() {
|
|
1282
|
+
if (!TranslationService.instance) {
|
|
1283
|
+
TranslationService.instance = new TranslationService;
|
|
1284
|
+
}
|
|
1285
|
+
return TranslationService.instance;
|
|
1286
|
+
}
|
|
1287
|
+
setLocale(locale) {
|
|
1288
|
+
this.currentLocale = I18nManager2.setLocale(locale);
|
|
1289
|
+
}
|
|
1290
|
+
getLocale() {
|
|
1291
|
+
return this.currentLocale;
|
|
1292
|
+
}
|
|
1293
|
+
t(key, params) {
|
|
1294
|
+
return I18nManager2.t(key, params, this.currentLocale);
|
|
1295
|
+
}
|
|
1296
|
+
tLocale(key, locale, params) {
|
|
1297
|
+
return I18nManager2.t(key, params, locale);
|
|
1298
|
+
}
|
|
1299
|
+
has(key) {
|
|
1300
|
+
return I18nManager2.has(key, this.currentLocale);
|
|
1301
|
+
}
|
|
1302
|
+
getAvailableLocales() {
|
|
1303
|
+
return I18nManager2.getAvailableLocales();
|
|
1304
|
+
}
|
|
1305
|
+
}
|
|
1306
|
+
var translate2 = TranslationService.getInstance();
|
|
1307
|
+
|
|
1308
|
+
// ../packager/packager-core/src/i18n/index.ts
|
|
1309
|
+
I18nManager2.registerTranslations("en", en2);
|
|
1310
|
+
I18nManager2.registerTranslations("de", de);
|
|
1311
|
+
I18nManager2.registerTranslations("es", es);
|
|
1312
|
+
I18nManager2.registerTranslations("es-mx", es_MX);
|
|
1313
|
+
I18nManager2.registerTranslations("fr", fr);
|
|
1314
|
+
I18nManager2.registerTranslations("ja", ja);
|
|
1315
|
+
I18nManager2.registerTranslations("ko", ko);
|
|
1316
|
+
I18nManager2.registerTranslations("pt", pt);
|
|
1317
|
+
I18nManager2.registerTranslations("pt-br", pt_BR);
|
|
1318
|
+
I18nManager2.registerTranslations("ro", ro);
|
|
1319
|
+
I18nManager2.registerTranslations("ru", ru);
|
|
1320
|
+
I18nManager2.registerTranslations("tr", tr);
|
|
1321
|
+
I18nManager2.registerTranslations("zh-cn", zh_CN);
|
|
1322
|
+
I18nManager2.registerTranslations("zh-tw", zh_TW);
|
|
1323
|
+
I18nManager2.registerTranslations("zu", zu);
|
|
1324
|
+
I18nManager2.setLocale("en");
|
|
1325
|
+
// ../packager/packager-core/src/services/tools-factory-repository.ts
|
|
1326
|
+
class ToolsFactoryRepository {
|
|
1327
|
+
projectFactoryMap = new Map;
|
|
1328
|
+
solutionFactory = null;
|
|
1329
|
+
registerProjectToolFactory(factory) {
|
|
1330
|
+
for (const type of factory.supportedTypes) {
|
|
1331
|
+
const existing = this.projectFactoryMap.get(type);
|
|
1332
|
+
if (existing) {
|
|
1333
|
+
if (existing.constructor?.name !== factory.constructor?.name) {
|
|
1334
|
+
console.warn(`Tool factory conflict for project type '${type}': ` + `'${existing.constructor?.name}' already registered, ` + `ignoring '${factory.constructor?.name}'.`);
|
|
1335
|
+
}
|
|
1336
|
+
continue;
|
|
1337
|
+
}
|
|
1338
|
+
this.projectFactoryMap.set(type, factory);
|
|
1339
|
+
}
|
|
1340
|
+
}
|
|
1341
|
+
registerSolutionToolFactory(factory) {
|
|
1342
|
+
this.solutionFactory = factory;
|
|
1343
|
+
}
|
|
1344
|
+
getSolutionToolFactory() {
|
|
1345
|
+
if (!this.solutionFactory) {
|
|
1346
|
+
throw new Error("No solution tool factory is registered");
|
|
1347
|
+
}
|
|
1348
|
+
return this.solutionFactory;
|
|
1349
|
+
}
|
|
1350
|
+
canHandleProject(projectType) {
|
|
1351
|
+
return this.projectFactoryMap.has(projectType);
|
|
1352
|
+
}
|
|
1353
|
+
getProjectToolFactory(projectType) {
|
|
1354
|
+
const factory = this.projectFactoryMap.get(projectType);
|
|
1355
|
+
if (!factory) {
|
|
1356
|
+
throw new Error(`No tool factory found for project type '${projectType}'`);
|
|
1357
|
+
}
|
|
1358
|
+
return factory;
|
|
1359
|
+
}
|
|
1360
|
+
reset() {
|
|
1361
|
+
this.projectFactoryMap.clear();
|
|
1362
|
+
this.solutionFactory = null;
|
|
1363
|
+
}
|
|
1364
|
+
}
|
|
1365
|
+
var REGISTRY_KEY = Symbol.for("@uipath/solutionpackager-tool-core/toolsFactoryRepository");
|
|
1366
|
+
var _global = globalThis;
|
|
1367
|
+
if (!_global[REGISTRY_KEY]) {
|
|
1368
|
+
_global[REGISTRY_KEY] = new ToolsFactoryRepository;
|
|
1369
|
+
}
|
|
1370
|
+
var toolsFactoryRepository = _global[REGISTRY_KEY];
|
|
1371
|
+
// src/packager-tool.ts
|
|
1372
|
+
function registerPackagerFactories() {
|
|
1373
|
+
toolsFactoryRepository.registerProjectToolFactory(new ApiWorkflowToolFactory);
|
|
1374
|
+
}
|
|
1375
|
+
|
|
1376
|
+
export { registerPackagerFactories };
|
|
1377
|
+
|
|
1378
|
+
//# debugId=9E99B96F468A8D8864756E2164756E21
|