@webiny/project 6.2.0 → 6.3.0-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/extensions/ApiBuildParam.js +3 -3
- package/extensions/ApiBuildParam.js.map +1 -1
- package/extensions/DatabaseSetup.d.ts +1 -1
- package/extensions/FeatureFlags.d.ts +12 -0
- package/extensions/FeatureFlags.js +12 -0
- package/extensions/FeatureFlags.js.map +1 -1
- package/extensions/ProjectDecorator.d.ts +1 -1
- package/extensions/ProjectId.d.ts +1 -1
- package/extensions/ProjectImplementation.d.ts +1 -1
- package/extensions/Telemetry.d.ts +1 -1
- package/extensions/index.d.ts +23 -11
- package/package.json +15 -15
- package/services/BuildAppWorkspaceService/BuildAppWorkspaceService.js +4 -4
- package/services/BuildAppWorkspaceService/BuildAppWorkspaceService.js.map +1 -1
- package/services/ProjectInfoService/ProjectInfoService.js.map +1 -1
|
@@ -95,7 +95,7 @@ export default BuildParam.createImplementation({
|
|
|
95
95
|
|
|
96
96
|
// Add the registration to the plugins array.
|
|
97
97
|
const pluginsArray = source.getFirstDescendant(node => Node.isArrayLiteralExpression(node));
|
|
98
|
-
pluginsArray.addElement(`\
|
|
98
|
+
pluginsArray.addElement(`\ncreateRegisterExtensionPlugin(ctx => {\n\tregisterExtension(ctx.container, ${className});\n})`);
|
|
99
99
|
{
|
|
100
100
|
let index = 1;
|
|
101
101
|
const importDeclarations = source.getImportDeclarations();
|
|
@@ -103,11 +103,11 @@ export default BuildParam.createImplementation({
|
|
|
103
103
|
const last = importDeclarations[importDeclarations.length - 1];
|
|
104
104
|
index = last.getChildIndex() + 1;
|
|
105
105
|
}
|
|
106
|
-
const contextPluginImportPath = "@webiny/
|
|
106
|
+
const contextPluginImportPath = "@webiny/handler/plugins/RegisterExtensionPlugin";
|
|
107
107
|
const existingContextPluginImport = source.getImportDeclaration(contextPluginImportPath);
|
|
108
108
|
if (!existingContextPluginImport) {
|
|
109
109
|
source.insertImportDeclaration(index, {
|
|
110
|
-
namedImports: ["
|
|
110
|
+
namedImports: ["createRegisterExtensionPlugin"],
|
|
111
111
|
moduleSpecifier: contextPluginImportPath
|
|
112
112
|
});
|
|
113
113
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["z","Node","Project","defineExtension","crypto","path","fs","BuildParam","type","tags","runtimeContext","appName","description","multiple","paramsSchema","object","paramName","string","value","union","record","any","array","number","boolean","build","params","ctx","extensionsTsFilePath","project","paths","workspaceFolder","join","toString","buildParamsDir","valueStr","JSON","stringify","hash","createHash","update","digest","className","slice","fileName","filePath","existsSync","mkdirSync","recursive","fileContent","writeFileSync","addSourceFileAtPath","source","getSourceFileOrThrow","importPath","relative","dirname","replace","startsWith","existingImportDeclaration","getImportDeclaration","index","importDeclarations","getImportDeclarations","length","last","getChildIndex","insertImportDeclaration","defaultImport","moduleSpecifier","pluginsArray","getFirstDescendant","node","isArrayLiteralExpression","addElement","contextPluginImportPath","existingContextPluginImport","namedImports","save"],"sources":["ApiBuildParam.ts"],"sourcesContent":["import { z } from \"zod\";\nimport { Node, Project, ArrayLiteralExpression } from \"ts-morph\";\nimport { defineExtension } from \"~/defineExtension/index.js\";\nimport crypto from \"crypto\";\nimport path from \"path\";\nimport fs from \"fs\";\n\nexport const BuildParam = defineExtension({\n type: \"Api/BuildParam\",\n tags: { runtimeContext: \"app-build\", appName: \"api\" },\n description: \"Add build-time parameter to API app.\",\n multiple: true,\n paramsSchema: () => {\n return z.object({\n paramName: z.string(),\n value: z.union([\n z.string(),\n z.record(z.string(), z.any()),\n z.array(z.any()),\n z.number(),\n z.boolean()\n ])\n });\n },\n async build(params, ctx) {\n const extensionsTsFilePath = ctx.project.paths.workspaceFolder\n .join(\"apps\", \"api\", \"graphql\", \"src\", \"extensions.ts\")\n .toString();\n\n const buildParamsDir = ctx.project.paths.workspaceFolder\n .join(\"apps\", \"api\", \"graphql\", \"src\", \"buildParams\")\n .toString();\n\n const { paramName, value } = params;\n\n // Serialize value to a TypeScript literal.\n const valueStr = JSON.stringify(value, null, 4);\n\n // Generate a unique class name based on the paramName.\n const hash = crypto.createHash(\"sha256\").update(paramName).digest(\"hex\");\n const className = `BuildParam_${hash.slice(-10)}`;\n const fileName = `${className}.ts`;\n const filePath = path.join(buildParamsDir, fileName);\n\n // Ensure buildParams directory exists.\n if (!fs.existsSync(buildParamsDir)) {\n fs.mkdirSync(buildParamsDir, { recursive: true });\n }\n\n // Check if file already exists.\n if (fs.existsSync(filePath)) {\n // File exists, just ensure it's imported in extensions.ts\n } else {\n // Create the BuildParam implementation file.\n const fileContent = `import { BuildParam } from \"webiny/api/build-params\";\n\nclass ${className} implements BuildParam.Interface {\n key = \"${paramName}\";\n value = ${valueStr};\n}\n\nexport default BuildParam.createImplementation({\n implementation: ${className},\n dependencies: []\n});\n`;\n fs.writeFileSync(filePath, fileContent, \"utf8\");\n }\n\n // Now update extensions.ts to import and register this BuildParam.\n const project = new Project();\n project.addSourceFileAtPath(extensionsTsFilePath);\n\n const source = project.getSourceFileOrThrow(extensionsTsFilePath);\n\n // Calculate import path relative to extensions.ts.\n let importPath = path\n .relative(path.dirname(extensionsTsFilePath), filePath)\n .replace(/\\.tsx?$/, \".js\");\n\n // Ensure the path starts with ./\n if (!importPath.startsWith(\".\")) {\n importPath = \"./\" + importPath;\n }\n\n // Check if import already exists.\n const existingImportDeclaration = source.getImportDeclaration(importPath);\n if (existingImportDeclaration) {\n return;\n }\n\n let index = 1;\n\n const importDeclarations = source.getImportDeclarations();\n if (importDeclarations.length) {\n const last = importDeclarations[importDeclarations.length - 1];\n index = last.getChildIndex() + 1;\n }\n\n // Add import for the BuildParam implementation.\n source.insertImportDeclaration(index, {\n defaultImport: className,\n moduleSpecifier: importPath\n });\n\n // Add the registration to the plugins array.\n const pluginsArray = source.getFirstDescendant(node =>\n Node.isArrayLiteralExpression(node)\n ) as ArrayLiteralExpression;\n\n pluginsArray.addElement(\n `\\
|
|
1
|
+
{"version":3,"names":["z","Node","Project","defineExtension","crypto","path","fs","BuildParam","type","tags","runtimeContext","appName","description","multiple","paramsSchema","object","paramName","string","value","union","record","any","array","number","boolean","build","params","ctx","extensionsTsFilePath","project","paths","workspaceFolder","join","toString","buildParamsDir","valueStr","JSON","stringify","hash","createHash","update","digest","className","slice","fileName","filePath","existsSync","mkdirSync","recursive","fileContent","writeFileSync","addSourceFileAtPath","source","getSourceFileOrThrow","importPath","relative","dirname","replace","startsWith","existingImportDeclaration","getImportDeclaration","index","importDeclarations","getImportDeclarations","length","last","getChildIndex","insertImportDeclaration","defaultImport","moduleSpecifier","pluginsArray","getFirstDescendant","node","isArrayLiteralExpression","addElement","contextPluginImportPath","existingContextPluginImport","namedImports","save"],"sources":["ApiBuildParam.ts"],"sourcesContent":["import { z } from \"zod\";\nimport { Node, Project, ArrayLiteralExpression } from \"ts-morph\";\nimport { defineExtension } from \"~/defineExtension/index.js\";\nimport crypto from \"crypto\";\nimport path from \"path\";\nimport fs from \"fs\";\n\nexport const BuildParam = defineExtension({\n type: \"Api/BuildParam\",\n tags: { runtimeContext: \"app-build\", appName: \"api\" },\n description: \"Add build-time parameter to API app.\",\n multiple: true,\n paramsSchema: () => {\n return z.object({\n paramName: z.string(),\n value: z.union([\n z.string(),\n z.record(z.string(), z.any()),\n z.array(z.any()),\n z.number(),\n z.boolean()\n ])\n });\n },\n async build(params, ctx) {\n const extensionsTsFilePath = ctx.project.paths.workspaceFolder\n .join(\"apps\", \"api\", \"graphql\", \"src\", \"extensions.ts\")\n .toString();\n\n const buildParamsDir = ctx.project.paths.workspaceFolder\n .join(\"apps\", \"api\", \"graphql\", \"src\", \"buildParams\")\n .toString();\n\n const { paramName, value } = params;\n\n // Serialize value to a TypeScript literal.\n const valueStr = JSON.stringify(value, null, 4);\n\n // Generate a unique class name based on the paramName.\n const hash = crypto.createHash(\"sha256\").update(paramName).digest(\"hex\");\n const className = `BuildParam_${hash.slice(-10)}`;\n const fileName = `${className}.ts`;\n const filePath = path.join(buildParamsDir, fileName);\n\n // Ensure buildParams directory exists.\n if (!fs.existsSync(buildParamsDir)) {\n fs.mkdirSync(buildParamsDir, { recursive: true });\n }\n\n // Check if file already exists.\n if (fs.existsSync(filePath)) {\n // File exists, just ensure it's imported in extensions.ts\n } else {\n // Create the BuildParam implementation file.\n const fileContent = `import { BuildParam } from \"webiny/api/build-params\";\n\nclass ${className} implements BuildParam.Interface {\n key = \"${paramName}\";\n value = ${valueStr};\n}\n\nexport default BuildParam.createImplementation({\n implementation: ${className},\n dependencies: []\n});\n`;\n fs.writeFileSync(filePath, fileContent, \"utf8\");\n }\n\n // Now update extensions.ts to import and register this BuildParam.\n const project = new Project();\n project.addSourceFileAtPath(extensionsTsFilePath);\n\n const source = project.getSourceFileOrThrow(extensionsTsFilePath);\n\n // Calculate import path relative to extensions.ts.\n let importPath = path\n .relative(path.dirname(extensionsTsFilePath), filePath)\n .replace(/\\.tsx?$/, \".js\");\n\n // Ensure the path starts with ./\n if (!importPath.startsWith(\".\")) {\n importPath = \"./\" + importPath;\n }\n\n // Check if import already exists.\n const existingImportDeclaration = source.getImportDeclaration(importPath);\n if (existingImportDeclaration) {\n return;\n }\n\n let index = 1;\n\n const importDeclarations = source.getImportDeclarations();\n if (importDeclarations.length) {\n const last = importDeclarations[importDeclarations.length - 1];\n index = last.getChildIndex() + 1;\n }\n\n // Add import for the BuildParam implementation.\n source.insertImportDeclaration(index, {\n defaultImport: className,\n moduleSpecifier: importPath\n });\n\n // Add the registration to the plugins array.\n const pluginsArray = source.getFirstDescendant(node =>\n Node.isArrayLiteralExpression(node)\n ) as ArrayLiteralExpression;\n\n pluginsArray.addElement(\n `\\ncreateRegisterExtensionPlugin(ctx => {\\n\\tregisterExtension(ctx.container, ${className});\\n})`\n );\n\n {\n let index = 1;\n\n const importDeclarations = source.getImportDeclarations();\n if (importDeclarations.length) {\n const last = importDeclarations[importDeclarations.length - 1];\n index = last.getChildIndex() + 1;\n }\n\n const contextPluginImportPath = \"@webiny/handler/plugins/RegisterExtensionPlugin\";\n const existingContextPluginImport =\n source.getImportDeclaration(contextPluginImportPath);\n if (!existingContextPluginImport) {\n source.insertImportDeclaration(index, {\n namedImports: [\"createRegisterExtensionPlugin\"],\n moduleSpecifier: contextPluginImportPath\n });\n }\n }\n\n await source.save();\n }\n});\n"],"mappings":"AAAA,SAASA,CAAC,QAAQ,KAAK;AACvB,SAASC,IAAI,EAAEC,OAAO,QAAgC,UAAU;AAChE,SAASC,eAAe;AACxB,OAAOC,MAAM,MAAM,QAAQ;AAC3B,OAAOC,IAAI,MAAM,MAAM;AACvB,OAAOC,EAAE,MAAM,IAAI;AAEnB,OAAO,MAAMC,UAAU,GAAGJ,eAAe,CAAC;EACtCK,IAAI,EAAE,gBAAgB;EACtBC,IAAI,EAAE;IAAEC,cAAc,EAAE,WAAW;IAAEC,OAAO,EAAE;EAAM,CAAC;EACrDC,WAAW,EAAE,sCAAsC;EACnDC,QAAQ,EAAE,IAAI;EACdC,YAAY,EAAEA,CAAA,KAAM;IAChB,OAAOd,CAAC,CAACe,MAAM,CAAC;MACZC,SAAS,EAAEhB,CAAC,CAACiB,MAAM,CAAC,CAAC;MACrBC,KAAK,EAAElB,CAAC,CAACmB,KAAK,CAAC,CACXnB,CAAC,CAACiB,MAAM,CAAC,CAAC,EACVjB,CAAC,CAACoB,MAAM,CAACpB,CAAC,CAACiB,MAAM,CAAC,CAAC,EAAEjB,CAAC,CAACqB,GAAG,CAAC,CAAC,CAAC,EAC7BrB,CAAC,CAACsB,KAAK,CAACtB,CAAC,CAACqB,GAAG,CAAC,CAAC,CAAC,EAChBrB,CAAC,CAACuB,MAAM,CAAC,CAAC,EACVvB,CAAC,CAACwB,OAAO,CAAC,CAAC,CACd;IACL,CAAC,CAAC;EACN,CAAC;EACD,MAAMC,KAAKA,CAACC,MAAM,EAAEC,GAAG,EAAE;IACrB,MAAMC,oBAAoB,GAAGD,GAAG,CAACE,OAAO,CAACC,KAAK,CAACC,eAAe,CACzDC,IAAI,CAAC,MAAM,EAAE,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GAAGV,MAAM,CAACW,qBAAqB,CAAC,CAAC;MACzD,IAAID,kBAAkB,CAACE,MAAM,EAAE;QAC3B,MAAMC,IAAI,GAAGH,kBAAkB,CAACA,kBAAkB,CAACE,MAAM,GAAG,CAAC,CAAC;QAC9DH,KAAK,GAAGI,IAAI,CAACC,aAAa,CAAC,CAAC,GAAG,CAAC;MACpC;MAEA,MAAMS,uBAAuB,GAAG,iDAAiD;MACjF,MAAMC,2BAA2B,GAC7BxB,MAAM,CAACQ,oBAAoB,CAACe,uBAAuB,CAAC;MACxD,IAAI,CAACC,2BAA2B,EAAE;QAC9BxB,MAAM,CAACe,uBAAuB,CAACN,KAAK,EAAE;UAClCgB,YAAY,EAAE,CAAC,+BAA+B,CAAC;UAC/CR,eAAe,EAAEM;QACrB,CAAC,CAAC;MACN;IACJ;IAEA,MAAMvB,MAAM,CAAC0B,IAAI,CAAC,CAAC;EACvB;AACJ,CAAC,CAAC","ignoreList":[]}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
|
-
export declare const DatabaseSetup: import("
|
|
2
|
+
export declare const DatabaseSetup: import("./index.js").ExtensionComponent<z.ZodObject<{
|
|
3
3
|
setupName: z.ZodEnum<{
|
|
4
4
|
ddb: "ddb";
|
|
5
5
|
"ddb+es": "ddb+es";
|
|
@@ -14,5 +14,17 @@ export declare const FeatureFlags: import("~/defineExtension/index.js").Extensio
|
|
|
14
14
|
fileManager: z.ZodOptional<z.ZodObject<{
|
|
15
15
|
threatDetection: z.ZodOptional<z.ZodBoolean>;
|
|
16
16
|
}, z.core.$strip>>;
|
|
17
|
+
aiPowerups: z.ZodOptional<z.ZodObject<{
|
|
18
|
+
enabled: z.ZodOptional<z.ZodBoolean>;
|
|
19
|
+
options: z.ZodOptional<z.ZodObject<{
|
|
20
|
+
websiteBuilder: z.ZodOptional<z.ZodObject<{
|
|
21
|
+
pageGeneration: z.ZodOptional<z.ZodBoolean>;
|
|
22
|
+
}, z.core.$strip>>;
|
|
23
|
+
fileManager: z.ZodOptional<z.ZodObject<{
|
|
24
|
+
imageEnrichment: z.ZodOptional<z.ZodBoolean>;
|
|
25
|
+
}, z.core.$strip>>;
|
|
26
|
+
lexicalGeneration: z.ZodOptional<z.ZodBoolean>;
|
|
27
|
+
}, z.core.$strip>>;
|
|
28
|
+
}, z.core.$strip>>;
|
|
17
29
|
}, z.core.$strip>;
|
|
18
30
|
}, z.core.$strip>>;
|
|
@@ -24,6 +24,18 @@ export const FeatureFlags = defineExtension({
|
|
|
24
24
|
recordLocking: z.boolean().optional(),
|
|
25
25
|
fileManager: z.object({
|
|
26
26
|
threatDetection: z.boolean().optional()
|
|
27
|
+
}).optional(),
|
|
28
|
+
aiPowerups: z.object({
|
|
29
|
+
enabled: z.boolean().optional(),
|
|
30
|
+
options: z.object({
|
|
31
|
+
websiteBuilder: z.object({
|
|
32
|
+
pageGeneration: z.boolean().optional()
|
|
33
|
+
}).optional(),
|
|
34
|
+
fileManager: z.object({
|
|
35
|
+
imageEnrichment: z.boolean().optional()
|
|
36
|
+
}).optional(),
|
|
37
|
+
lexicalGeneration: z.boolean().optional()
|
|
38
|
+
}).optional()
|
|
27
39
|
}).optional()
|
|
28
40
|
})
|
|
29
41
|
}),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","z","BuildParam","AdminBuildParam","defineExtension","FeatureFlags","type","tags","runtimeContext","description","paramsSchema","object","features","multiTenancy","boolean","optional","advancedPublishingWorkflow","advancedAccessControlLayer","union","teams","privateFiles","folderLevelPermissions","hcmsFieldPermissions","auditLogs","recordLocking","fileManager","threatDetection","render","createElement","Fragment","paramName","value"],"sources":["FeatureFlags.tsx"],"sourcesContent":["import React from \"react\";\nimport { z } from \"zod\";\nimport { BuildParam } from \"./ApiBuildParam.js\";\nimport { AdminBuildParam } from \"./AdminBuildParam.js\";\nimport { defineExtension } from \"~/defineExtension/index.js\";\n\nexport const FeatureFlags = defineExtension({\n type: \"FeatureFlags\",\n tags: { runtimeContext: \"project\" },\n description: \"Enable or disable WCP features.\",\n paramsSchema: z.object({\n // Follows `IFeatureFlagsDto` from `packages/feature-flags/src/types.ts`.\n features: z.object({\n multiTenancy: z.boolean().optional(),\n advancedPublishingWorkflow: z.boolean().optional(),\n advancedAccessControlLayer: z\n .union([\n z.boolean(),\n z.object({\n teams: z.boolean().optional(),\n privateFiles: z.boolean().optional(),\n folderLevelPermissions: z.boolean().optional(),\n hcmsFieldPermissions: z.boolean().optional()\n })\n ])\n .optional(),\n auditLogs: z.boolean().optional(),\n recordLocking: z.boolean().optional(),\n fileManager: z\n .object({\n threatDetection: z.boolean().optional()\n })\n .optional()\n })\n }),\n render: ({ features = {} }) => {\n return (\n <>\n <BuildParam paramName=\"FeatureFlags\" value={features} />\n <AdminBuildParam paramName=\"FeatureFlags\" value={features} />\n </>\n );\n }\n});\n"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,CAAC,QAAQ,KAAK;AACvB,SAASC,UAAU;AACnB,SAASC,eAAe;AACxB,SAASC,eAAe;AAExB,OAAO,MAAMC,YAAY,GAAGD,eAAe,CAAC;EACxCE,IAAI,EAAE,cAAc;EACpBC,IAAI,EAAE;IAAEC,cAAc,EAAE;EAAU,CAAC;EACnCC,WAAW,EAAE,iCAAiC;EAC9CC,YAAY,EAAET,CAAC,CAACU,MAAM,CAAC;IACnB;IACAC,QAAQ,EAAEX,CAAC,CAACU,MAAM,CAAC;MACfE,YAAY,EAAEZ,CAAC,CAACa,OAAO,CAAC,CAAC,CAACC,QAAQ,CAAC,CAAC;MACpCC,0BAA0B,EAAEf,CAAC,CAACa,OAAO,CAAC,CAAC,CAACC,QAAQ,CAAC,CAAC;MAClDE,0BAA0B,EAAEhB,CAAC,CACxBiB,KAAK,CAAC,CACHjB,CAAC,CAACa,OAAO,CAAC,CAAC,EACXb,CAAC,CAACU,MAAM,CAAC;QACLQ,KAAK,EAAElB,CAAC,CAACa,OAAO,CAAC,CAAC,CAACC,QAAQ,CAAC,CAAC;QAC7BK,YAAY,EAAEnB,CAAC,CAACa,OAAO,CAAC,CAAC,CAACC,QAAQ,CAAC,CAAC;QACpCM,sBAAsB,EAAEpB,CAAC,CAACa,OAAO,CAAC,CAAC,CAACC,QAAQ,CAAC,CAAC;QAC9CO,oBAAoB,EAAErB,CAAC,CAACa,OAAO,CAAC,CAAC,CAACC,QAAQ,CAAC;MAC/C,CAAC,CAAC,CACL,CAAC,CACDA,QAAQ,CAAC,CAAC;MACfQ,SAAS,EAAEtB,CAAC,CAACa,OAAO,CAAC,CAAC,CAACC,QAAQ,CAAC,CAAC;MACjCS,aAAa,EAAEvB,CAAC,CAACa,OAAO,CAAC,CAAC,CAACC,QAAQ,CAAC,CAAC;MACrCU,WAAW,EAAExB,CAAC,CACTU,MAAM,CAAC;QACJe,eAAe,EAAEzB,CAAC,CAACa,OAAO,CAAC,CAAC,CAACC,QAAQ,CAAC;MAC1C,CAAC,CAAC,CACDA,QAAQ,CAAC;IAClB,CAAC;EACL,CAAC,CAAC;
|
|
1
|
+
{"version":3,"names":["React","z","BuildParam","AdminBuildParam","defineExtension","FeatureFlags","type","tags","runtimeContext","description","paramsSchema","object","features","multiTenancy","boolean","optional","advancedPublishingWorkflow","advancedAccessControlLayer","union","teams","privateFiles","folderLevelPermissions","hcmsFieldPermissions","auditLogs","recordLocking","fileManager","threatDetection","aiPowerups","enabled","options","websiteBuilder","pageGeneration","imageEnrichment","lexicalGeneration","render","createElement","Fragment","paramName","value"],"sources":["FeatureFlags.tsx"],"sourcesContent":["import React from \"react\";\nimport { z } from \"zod\";\nimport { BuildParam } from \"./ApiBuildParam.js\";\nimport { AdminBuildParam } from \"./AdminBuildParam.js\";\nimport { defineExtension } from \"~/defineExtension/index.js\";\n\nexport const FeatureFlags = defineExtension({\n type: \"FeatureFlags\",\n tags: { runtimeContext: \"project\" },\n description: \"Enable or disable WCP features.\",\n paramsSchema: z.object({\n // Follows `IFeatureFlagsDto` from `packages/feature-flags/src/types.ts`.\n features: z.object({\n multiTenancy: z.boolean().optional(),\n advancedPublishingWorkflow: z.boolean().optional(),\n advancedAccessControlLayer: z\n .union([\n z.boolean(),\n z.object({\n teams: z.boolean().optional(),\n privateFiles: z.boolean().optional(),\n folderLevelPermissions: z.boolean().optional(),\n hcmsFieldPermissions: z.boolean().optional()\n })\n ])\n .optional(),\n auditLogs: z.boolean().optional(),\n recordLocking: z.boolean().optional(),\n fileManager: z\n .object({\n threatDetection: z.boolean().optional()\n })\n .optional(),\n aiPowerups: z\n .object({\n enabled: z.boolean().optional(),\n options: z\n .object({\n websiteBuilder: z\n .object({\n pageGeneration: z.boolean().optional()\n })\n .optional(),\n fileManager: z\n .object({\n imageEnrichment: z.boolean().optional()\n })\n .optional(),\n lexicalGeneration: z.boolean().optional()\n })\n .optional()\n })\n .optional()\n })\n }),\n render: ({ features = {} }) => {\n return (\n <>\n <BuildParam paramName=\"FeatureFlags\" value={features} />\n <AdminBuildParam paramName=\"FeatureFlags\" value={features} />\n </>\n );\n }\n});\n"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,CAAC,QAAQ,KAAK;AACvB,SAASC,UAAU;AACnB,SAASC,eAAe;AACxB,SAASC,eAAe;AAExB,OAAO,MAAMC,YAAY,GAAGD,eAAe,CAAC;EACxCE,IAAI,EAAE,cAAc;EACpBC,IAAI,EAAE;IAAEC,cAAc,EAAE;EAAU,CAAC;EACnCC,WAAW,EAAE,iCAAiC;EAC9CC,YAAY,EAAET,CAAC,CAACU,MAAM,CAAC;IACnB;IACAC,QAAQ,EAAEX,CAAC,CAACU,MAAM,CAAC;MACfE,YAAY,EAAEZ,CAAC,CAACa,OAAO,CAAC,CAAC,CAACC,QAAQ,CAAC,CAAC;MACpCC,0BAA0B,EAAEf,CAAC,CAACa,OAAO,CAAC,CAAC,CAACC,QAAQ,CAAC,CAAC;MAClDE,0BAA0B,EAAEhB,CAAC,CACxBiB,KAAK,CAAC,CACHjB,CAAC,CAACa,OAAO,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AC,CAACa,OAAO,CAAC,CAAC,CAACC,QAAQ,CAAC;QAC5C,CAAC,CAAC,CACDA,QAAQ,CAAC;MAClB,CAAC,CAAC,CACDA,QAAQ,CAAC;IAClB,CAAC;EACL,CAAC,CAAC;EACFmB,MAAM,EAAEA,CAAC;IAAEtB,QAAQ,GAAG,CAAC;EAAE,CAAC,KAAK;IAC3B,oBACIZ,KAAA,CAAAmC,aAAA,CAAAnC,KAAA,CAAAoC,QAAA,qBACIpC,KAAA,CAAAmC,aAAA,CAACjC,UAAU;MAACmC,SAAS,EAAC,cAAc;MAACC,KAAK,EAAE1B;IAAS,CAAE,CAAC,eACxDZ,KAAA,CAAAmC,aAAA,CAAChC,eAAe;MAACkC,SAAS,EAAC,cAAc;MAACC,KAAK,EAAE1B;IAAS,CAAE,CAC9D,CAAC;EAEX;AACJ,CAAC,CAAC","ignoreList":[]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
|
-
export declare const ProjectDecorator: import("
|
|
2
|
+
export declare const ProjectDecorator: import("./index.js").ExtensionComponent<z.ZodObject<{
|
|
3
3
|
src: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
|
|
4
4
|
}, z.core.$strip>>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
|
-
export declare const ProjectImplementation: import("
|
|
2
|
+
export declare const ProjectImplementation: import("./index.js").ExtensionComponent<z.ZodObject<{
|
|
3
3
|
src: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
|
|
4
4
|
singleton: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
5
5
|
}, z.core.$strip>>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
|
-
export declare const Telemetry: import("
|
|
2
|
+
export declare const Telemetry: import("./index.js").ExtensionComponent<z.ZodObject<{
|
|
3
3
|
enabled: z.ZodDefault<z.ZodBoolean>;
|
|
4
4
|
}, z.core.$strip>>;
|
package/extensions/index.d.ts
CHANGED
|
@@ -52,18 +52,18 @@ export { ProductionEnvironments };
|
|
|
52
52
|
export { CoreStackOutputValue };
|
|
53
53
|
export { ApiStackOutputValue };
|
|
54
54
|
export { AdminStackOutputValue };
|
|
55
|
-
export declare const definitions: (import("
|
|
55
|
+
export declare const definitions: (import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
56
56
|
src: import("zod").ZodString;
|
|
57
|
-
}, import("zod/v4/core").$strip>> | import("
|
|
57
|
+
}, import("zod/v4/core").$strip>> | import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
58
58
|
src: import("zod").ZodPipe<import("zod").ZodString, import("zod").ZodTransform<string, string>>;
|
|
59
|
-
}, import("zod/v4/core").$strip>> | import("
|
|
59
|
+
}, import("zod/v4/core").$strip>> | import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
60
60
|
enabled: import("zod").ZodDefault<import("zod").ZodBoolean>;
|
|
61
|
-
}, import("zod/v4/core").$strip>> | import("
|
|
61
|
+
}, import("zod/v4/core").$strip>> | import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
62
62
|
id: import("zod").ZodString;
|
|
63
|
-
}, import("zod/v4/core").$strip>> | import("
|
|
63
|
+
}, import("zod/v4/core").$strip>> | import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
64
64
|
varName: import("zod").ZodString;
|
|
65
65
|
value: import("zod").ZodString;
|
|
66
|
-
}, import("zod/v4/core").$strip>> | import("
|
|
66
|
+
}, import("zod/v4/core").$strip>> | import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
67
67
|
features: import("zod").ZodObject<{
|
|
68
68
|
multiTenancy: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
69
69
|
advancedPublishingWorkflow: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
@@ -78,21 +78,33 @@ export declare const definitions: (import("../defineExtension/index.js").Extensi
|
|
|
78
78
|
fileManager: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
79
79
|
threatDetection: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
80
80
|
}, import("zod/v4/core").$strip>>;
|
|
81
|
+
aiPowerups: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
82
|
+
enabled: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
83
|
+
options: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
84
|
+
websiteBuilder: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
85
|
+
pageGeneration: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
86
|
+
}, import("zod/v4/core").$strip>>;
|
|
87
|
+
fileManager: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
88
|
+
imageEnrichment: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
89
|
+
}, import("zod/v4/core").$strip>>;
|
|
90
|
+
lexicalGeneration: import("zod").ZodOptional<import("zod").ZodBoolean>;
|
|
91
|
+
}, import("zod/v4/core").$strip>>;
|
|
92
|
+
}, import("zod/v4/core").$strip>>;
|
|
81
93
|
}, import("zod/v4/core").$strip>;
|
|
82
|
-
}, import("zod/v4/core").$strip>> | import("
|
|
94
|
+
}, import("zod/v4/core").$strip>> | import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
83
95
|
prefix: import("zod").ZodString;
|
|
84
|
-
}, import("zod/v4/core").$strip>> | import("
|
|
96
|
+
}, import("zod/v4/core").$strip>> | import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
85
97
|
environments: import("zod").ZodArray<import("zod").ZodString>;
|
|
86
|
-
}, import("zod/v4/core").$strip>> | import("
|
|
98
|
+
}, import("zod/v4/core").$strip>> | import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
87
99
|
key: import("zod").ZodString;
|
|
88
100
|
value: import("zod").ZodAny;
|
|
89
|
-
}, import("zod/v4/core").$strip>> | import("
|
|
101
|
+
}, import("zod/v4/core").$strip>> | import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
90
102
|
setupName: import("zod").ZodEnum<{
|
|
91
103
|
ddb: "ddb";
|
|
92
104
|
"ddb+es": "ddb+es";
|
|
93
105
|
"ddb+os": "ddb+os";
|
|
94
106
|
}>;
|
|
95
|
-
}, import("zod/v4/core").$strip>> | import("
|
|
107
|
+
}, import("zod/v4/core").$strip>> | import("./index.js").ExtensionDefinitionModel<import("zod").ZodObject<{
|
|
96
108
|
paramName: import("zod").ZodString;
|
|
97
109
|
value: import("zod").ZodUnion<readonly [import("zod").ZodString, import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodAny>, import("zod").ZodArray<import("zod").ZodAny>, import("zod").ZodNumber, import("zod").ZodBoolean]>;
|
|
98
110
|
}, import("zod/v4/core").$strip>>)[];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@webiny/project",
|
|
3
|
-
"version": "6.
|
|
3
|
+
"version": "6.3.0-beta.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"repository": {
|
|
@@ -10,17 +10,17 @@
|
|
|
10
10
|
"description": "An SDK for managing Webiny projects.",
|
|
11
11
|
"license": "MIT",
|
|
12
12
|
"dependencies": {
|
|
13
|
-
"@webiny/aws-sdk": "6.
|
|
14
|
-
"@webiny/build-tools": "6.
|
|
13
|
+
"@webiny/aws-sdk": "6.3.0-beta.0",
|
|
14
|
+
"@webiny/build-tools": "6.3.0-beta.0",
|
|
15
15
|
"@webiny/di": "0.2.3",
|
|
16
|
-
"@webiny/feature-flags": "6.
|
|
17
|
-
"@webiny/global-config": "6.
|
|
18
|
-
"@webiny/pulumi-sdk": "6.
|
|
19
|
-
"@webiny/react-properties": "6.
|
|
20
|
-
"@webiny/system-requirements": "6.
|
|
21
|
-
"@webiny/telemetry": "6.
|
|
22
|
-
"@webiny/utils": "6.
|
|
23
|
-
"@webiny/wcp": "6.
|
|
16
|
+
"@webiny/feature-flags": "6.3.0-beta.0",
|
|
17
|
+
"@webiny/global-config": "6.3.0-beta.0",
|
|
18
|
+
"@webiny/pulumi-sdk": "6.3.0-beta.0",
|
|
19
|
+
"@webiny/react-properties": "6.3.0-beta.0",
|
|
20
|
+
"@webiny/system-requirements": "6.3.0-beta.0",
|
|
21
|
+
"@webiny/telemetry": "6.3.0-beta.0",
|
|
22
|
+
"@webiny/utils": "6.3.0-beta.0",
|
|
23
|
+
"@webiny/wcp": "6.3.0-beta.0",
|
|
24
24
|
"chalk": "5.6.2",
|
|
25
25
|
"chokidar": "5.0.0",
|
|
26
26
|
"ci-info": "4.4.0",
|
|
@@ -31,7 +31,7 @@
|
|
|
31
31
|
"exit-hook": "5.1.0",
|
|
32
32
|
"fast-glob": "3.3.3",
|
|
33
33
|
"find-up": "8.0.0",
|
|
34
|
-
"get-tsconfig": "4.
|
|
34
|
+
"get-tsconfig": "4.14.0",
|
|
35
35
|
"graphql-request": "7.4.0",
|
|
36
36
|
"humanize-duration": "3.33.2",
|
|
37
37
|
"jsdom": "29.0.2",
|
|
@@ -58,8 +58,8 @@
|
|
|
58
58
|
"@types/jsdom": "28.0.1",
|
|
59
59
|
"@types/lodash": "4.17.24",
|
|
60
60
|
"rimraf": "6.1.3",
|
|
61
|
-
"type-fest": "5.
|
|
62
|
-
"typescript": "
|
|
61
|
+
"type-fest": "5.6.0",
|
|
62
|
+
"typescript": "6.0.3"
|
|
63
63
|
},
|
|
64
64
|
"adio": {
|
|
65
65
|
"ignore": {
|
|
@@ -75,5 +75,5 @@
|
|
|
75
75
|
"access": "public",
|
|
76
76
|
"directory": "dist"
|
|
77
77
|
},
|
|
78
|
-
"gitHead": "
|
|
78
|
+
"gitHead": "94c21e58aebc9855bf1ae972423281faa0f5c135"
|
|
79
79
|
}
|
|
@@ -58,16 +58,16 @@ export class DefaultBuildAppWorkspaceService {
|
|
|
58
58
|
variant
|
|
59
59
|
} = sdkParams;
|
|
60
60
|
replaceInPath(path.join(appWorkspaceFolderPath, "/**/*.{ts,js,yaml}"), [{
|
|
61
|
-
find: "{PROJECT_ID}",
|
|
61
|
+
find: "%{PROJECT_ID}",
|
|
62
62
|
replaceWith: app.name
|
|
63
63
|
}, {
|
|
64
|
-
find: "{PROJECT_DESCRIPTION}",
|
|
64
|
+
find: "%{PROJECT_DESCRIPTION}",
|
|
65
65
|
replaceWith: `Webiny's ${env} app.`
|
|
66
66
|
}, {
|
|
67
|
-
find: "{DEPLOY_ENV}",
|
|
67
|
+
find: "%{DEPLOY_ENV}",
|
|
68
68
|
replaceWith: env
|
|
69
69
|
}, {
|
|
70
|
-
find: "{DEPLOY_VARIANT}",
|
|
70
|
+
find: "%{DEPLOY_VARIANT}",
|
|
71
71
|
replaceWith: !variant || variant === "undefined" ? "" : variant
|
|
72
72
|
}]);
|
|
73
73
|
this.loggerService.info("App workspace built successfully.");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["createImplementation","BuildAppWorkspaceService","GetApp","LoggerService","ProjectSdkParamsService","path","fs","replaceInPath","getTemplatesFolderPath","wait","Promise","resolve","setTimeout","DefaultBuildAppWorkspaceService","constructor","getApp","loggerService","projectSdkParamsService","execute","appName","options","sdkParams","get","debug","env","Error","templatesFolderPath","app","paths","workspaceFolder","existsSync","forceRebuild","rmSync","toString","recursive","force","appWorkspaceFolderPath","baseTemplateFolderPath","join","mkdirSync","cpSync","variant","find","replaceWith","name","info","buildAppWorkspaceService","abstraction","implementation","dependencies"],"sources":["BuildAppWorkspaceService.ts"],"sourcesContent":["import { createImplementation } from \"@webiny/di\";\nimport {\n BuildAppWorkspaceService,\n GetApp,\n LoggerService,\n ProjectSdkParamsService\n} from \"~/abstractions/index.js\";\n\nimport path from \"path\";\nimport fs from \"fs\";\nimport { replaceInPath } from \"replace-in-path\";\nimport { getTemplatesFolderPath } from \"~/utils/index.js\";\n\nconst wait = () => new Promise(resolve => setTimeout(resolve, 10));\n\nexport class DefaultBuildAppWorkspaceService implements BuildAppWorkspaceService.Interface {\n constructor(\n private getApp: GetApp.Interface,\n private loggerService: LoggerService.Interface,\n private projectSdkParamsService: ProjectSdkParamsService.Interface\n ) {}\n\n async execute(appName: GetApp.AppName, options: BuildAppWorkspaceService.Options = {}) {\n const sdkParams = this.projectSdkParamsService.get();\n this.loggerService.debug({ appName, options }, \"Building app workspace...\");\n\n if (!sdkParams.env) {\n throw new Error(`Please specify environment, for example \"dev\".`);\n }\n\n const templatesFolderPath = getTemplatesFolderPath();\n\n const app = this.getApp.execute(appName);\n if (app.paths.workspaceFolder.existsSync()) {\n // Only skip rebuild if the forceRebuild option is not set to true.\n if (options.forceRebuild !== true) {\n this.loggerService.debug(\n { appName },\n \"App workspace already exists, skipping rebuild.\"\n );\n return;\n }\n }\n\n // Clean up existing workspace folder if it exists.\n if (app.paths.workspaceFolder.existsSync()) {\n fs.rmSync(app.paths.workspaceFolder.toString(), { recursive: true, force: true });\n }\n\n const appWorkspaceFolderPath = app.paths.workspaceFolder.toString();\n const baseTemplateFolderPath = path.join(templatesFolderPath, \"appTemplates\", \"base\");\n\n fs.mkdirSync(appWorkspaceFolderPath, { recursive: true });\n\n // Wait a bit and make sure the files are ready to have their content replaced.\n await wait();\n\n fs.cpSync(baseTemplateFolderPath, appWorkspaceFolderPath, { recursive: true });\n\n // Wait a bit and make sure the files are ready to have their content replaced.\n await wait();\n\n const { env, variant } = sdkParams;\n\n replaceInPath(path.join(appWorkspaceFolderPath, \"/**/*.{ts,js,yaml}\"), [\n { find: \"{PROJECT_ID}\", replaceWith: app.name },\n { find: \"{PROJECT_DESCRIPTION}\", replaceWith: `Webiny's ${env} app.` },\n { find: \"{DEPLOY_ENV}\", replaceWith: env },\n {\n find: \"{DEPLOY_VARIANT}\",\n replaceWith: !variant || variant === \"undefined\" ? \"\" : variant\n }\n ]);\n\n this.loggerService.info(\"App workspace built successfully.\");\n }\n}\n\nexport const buildAppWorkspaceService = createImplementation({\n abstraction: BuildAppWorkspaceService,\n implementation: DefaultBuildAppWorkspaceService,\n dependencies: [GetApp, LoggerService, ProjectSdkParamsService]\n});\n"],"mappings":"AAAA,SAASA,oBAAoB,QAAQ,YAAY;AACjD,SACIC,wBAAwB,EACxBC,MAAM,EACNC,aAAa,EACbC,uBAAuB;AAG3B,OAAOC,IAAI,MAAM,MAAM;AACvB,OAAOC,EAAE,MAAM,IAAI;AACnB,SAASC,aAAa,QAAQ,iBAAiB;AAC/C,SAASC,sBAAsB;AAE/B,MAAMC,IAAI,GAAGA,CAAA,KAAM,IAAIC,OAAO,CAACC,OAAO,IAAIC,UAAU,CAACD,OAAO,EAAE,EAAE,CAAC,CAAC;AAElE,OAAO,MAAME,+BAA+B,CAA+C;EACvFC,WAAWA,CACCC,MAAwB,EACxBC,aAAsC,EACtCC,uBAA0D,EACpE;IAAA,KAHUF,MAAwB,GAAxBA,MAAwB;IAAA,KACxBC,aAAsC,GAAtCA,aAAsC;IAAA,KACtCC,uBAA0D,GAA1DA,uBAA0D;EACnE;EAEH,MAAMC,OAAOA,CAACC,OAAuB,EAAEC,OAAyC,GAAG,CAAC,CAAC,EAAE;IACnF,MAAMC,SAAS,GAAG,IAAI,CAACJ,uBAAuB,CAACK,GAAG,CAAC,CAAC;IACpD,IAAI,CAACN,aAAa,CAACO,KAAK,CAAC;MAAEJ,OAAO;MAAEC;IAAQ,CAAC,EAAE,2BAA2B,CAAC;IAE3E,IAAI,CAACC,SAAS,CAACG,GAAG,EAAE;MAChB,MAAM,IAAIC,KAAK,CAAC,gDAAgD,CAAC;IACrE;IAEA,MAAMC,mBAAmB,GAAGlB,sBAAsB,CAAC,CAAC;IAEpD,MAAMmB,GAAG,GAAG,IAAI,CAACZ,MAAM,CAACG,OAAO,CAACC,OAAO,CAAC;IACxC,IAAIQ,GAAG,CAACC,KAAK,CAACC,eAAe,CAACC,UAAU,CAAC,CAAC,EAAE;MACxC;MACA,IAAIV,OAAO,CAACW,YAAY,KAAK,IAAI,EAAE;QAC/B,IAAI,CAACf,aAAa,CAACO,KAAK,CACpB;UAAEJ;QAAQ,CAAC,EACX,iDACJ,CAAC;QACD;MACJ;IACJ;;IAEA;IACA,IAAIQ,GAAG,CAACC,KAAK,CAACC,eAAe,CAACC,UAAU,CAAC,CAAC,EAAE;MACxCxB,EAAE,CAAC0B,MAAM,CAACL,GAAG,CAACC,KAAK,CAACC,eAAe,CAACI,QAAQ,CAAC,CAAC,EAAE;QAAEC,SAAS,EAAE,IAAI;QAAEC,KAAK,EAAE;MAAK,CAAC,CAAC;IACrF;IAEA,MAAMC,sBAAsB,GAAGT,GAAG,CAACC,KAAK,CAACC,eAAe,CAACI,QAAQ,CAAC,CAAC;IACnE,MAAMI,sBAAsB,GAAGhC,IAAI,CAACiC,IAAI,CAACZ,mBAAmB,EAAE,cAAc,EAAE,MAAM,CAAC;IAErFpB,EAAE,CAACiC,SAAS,CAACH,sBAAsB,EAAE;MAAEF,SAAS,EAAE;IAAK,CAAC,CAAC;;IAEzD;IACA,MAAMzB,IAAI,CAAC,CAAC;IAEZH,EAAE,CAACkC,MAAM,CAACH,sBAAsB,EAAED,sBAAsB,EAAE;MAAEF,SAAS,EAAE;IAAK,CAAC,CAAC;;IAE9E;IACA,MAAMzB,IAAI,CAAC,CAAC;IAEZ,MAAM;MAAEe,GAAG;MAAEiB;IAAQ,CAAC,GAAGpB,SAAS;IAElCd,aAAa,CAACF,IAAI,CAACiC,IAAI,CAACF,sBAAsB,EAAE,oBAAoB,CAAC,EAAE,CACnE;MAAEM,IAAI,EAAE,
|
|
1
|
+
{"version":3,"names":["createImplementation","BuildAppWorkspaceService","GetApp","LoggerService","ProjectSdkParamsService","path","fs","replaceInPath","getTemplatesFolderPath","wait","Promise","resolve","setTimeout","DefaultBuildAppWorkspaceService","constructor","getApp","loggerService","projectSdkParamsService","execute","appName","options","sdkParams","get","debug","env","Error","templatesFolderPath","app","paths","workspaceFolder","existsSync","forceRebuild","rmSync","toString","recursive","force","appWorkspaceFolderPath","baseTemplateFolderPath","join","mkdirSync","cpSync","variant","find","replaceWith","name","info","buildAppWorkspaceService","abstraction","implementation","dependencies"],"sources":["BuildAppWorkspaceService.ts"],"sourcesContent":["import { createImplementation } from \"@webiny/di\";\nimport {\n BuildAppWorkspaceService,\n GetApp,\n LoggerService,\n ProjectSdkParamsService\n} from \"~/abstractions/index.js\";\n\nimport path from \"path\";\nimport fs from \"fs\";\nimport { replaceInPath } from \"replace-in-path\";\nimport { getTemplatesFolderPath } from \"~/utils/index.js\";\n\nconst wait = () => new Promise(resolve => setTimeout(resolve, 10));\n\nexport class DefaultBuildAppWorkspaceService implements BuildAppWorkspaceService.Interface {\n constructor(\n private getApp: GetApp.Interface,\n private loggerService: LoggerService.Interface,\n private projectSdkParamsService: ProjectSdkParamsService.Interface\n ) {}\n\n async execute(appName: GetApp.AppName, options: BuildAppWorkspaceService.Options = {}) {\n const sdkParams = this.projectSdkParamsService.get();\n this.loggerService.debug({ appName, options }, \"Building app workspace...\");\n\n if (!sdkParams.env) {\n throw new Error(`Please specify environment, for example \"dev\".`);\n }\n\n const templatesFolderPath = getTemplatesFolderPath();\n\n const app = this.getApp.execute(appName);\n if (app.paths.workspaceFolder.existsSync()) {\n // Only skip rebuild if the forceRebuild option is not set to true.\n if (options.forceRebuild !== true) {\n this.loggerService.debug(\n { appName },\n \"App workspace already exists, skipping rebuild.\"\n );\n return;\n }\n }\n\n // Clean up existing workspace folder if it exists.\n if (app.paths.workspaceFolder.existsSync()) {\n fs.rmSync(app.paths.workspaceFolder.toString(), { recursive: true, force: true });\n }\n\n const appWorkspaceFolderPath = app.paths.workspaceFolder.toString();\n const baseTemplateFolderPath = path.join(templatesFolderPath, \"appTemplates\", \"base\");\n\n fs.mkdirSync(appWorkspaceFolderPath, { recursive: true });\n\n // Wait a bit and make sure the files are ready to have their content replaced.\n await wait();\n\n fs.cpSync(baseTemplateFolderPath, appWorkspaceFolderPath, { recursive: true });\n\n // Wait a bit and make sure the files are ready to have their content replaced.\n await wait();\n\n const { env, variant } = sdkParams;\n\n replaceInPath(path.join(appWorkspaceFolderPath, \"/**/*.{ts,js,yaml}\"), [\n { find: \"%{PROJECT_ID}\", replaceWith: app.name },\n { find: \"%{PROJECT_DESCRIPTION}\", replaceWith: `Webiny's ${env} app.` },\n { find: \"%{DEPLOY_ENV}\", replaceWith: env },\n {\n find: \"%{DEPLOY_VARIANT}\",\n replaceWith: !variant || variant === \"undefined\" ? \"\" : variant\n }\n ]);\n\n this.loggerService.info(\"App workspace built successfully.\");\n }\n}\n\nexport const buildAppWorkspaceService = createImplementation({\n abstraction: BuildAppWorkspaceService,\n implementation: DefaultBuildAppWorkspaceService,\n dependencies: [GetApp, LoggerService, ProjectSdkParamsService]\n});\n"],"mappings":"AAAA,SAASA,oBAAoB,QAAQ,YAAY;AACjD,SACIC,wBAAwB,EACxBC,MAAM,EACNC,aAAa,EACbC,uBAAuB;AAG3B,OAAOC,IAAI,MAAM,MAAM;AACvB,OAAOC,EAAE,MAAM,IAAI;AACnB,SAASC,aAAa,QAAQ,iBAAiB;AAC/C,SAASC,sBAAsB;AAE/B,MAAMC,IAAI,GAAGA,CAAA,KAAM,IAAIC,OAAO,CAACC,OAAO,IAAIC,UAAU,CAACD,OAAO,EAAE,EAAE,CAAC,CAAC;AAElE,OAAO,MAAME,+BAA+B,CAA+C;EACvFC,WAAWA,CACCC,MAAwB,EACxBC,aAAsC,EACtCC,uBAA0D,EACpE;IAAA,KAHUF,MAAwB,GAAxBA,MAAwB;IAAA,KACxBC,aAAsC,GAAtCA,aAAsC;IAAA,KACtCC,uBAA0D,GAA1DA,uBAA0D;EACnE;EAEH,MAAMC,OAAOA,CAACC,OAAuB,EAAEC,OAAyC,GAAG,CAAC,CAAC,EAAE;IACnF,MAAMC,SAAS,GAAG,IAAI,CAACJ,uBAAuB,CAACK,GAAG,CAAC,CAAC;IACpD,IAAI,CAACN,aAAa,CAACO,KAAK,CAAC;MAAEJ,OAAO;MAAEC;IAAQ,CAAC,EAAE,2BAA2B,CAAC;IAE3E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I,CAACF,sBAAsB,EAAE,oBAAoB,CAAC,EAAE,CACnE;MAAEM,IAAI,EAAE,eAAe;MAAEC,WAAW,EAAEhB,GAAG,CAACiB;IAAK,CAAC,EAChD;MAAEF,IAAI,EAAE,wBAAwB;MAAEC,WAAW,EAAE,YAAYnB,GAAG;IAAQ,CAAC,EACvE;MAAEkB,IAAI,EAAE,eAAe;MAAEC,WAAW,EAAEnB;IAAI,CAAC,EAC3C;MACIkB,IAAI,EAAE,mBAAmB;MACzBC,WAAW,EAAE,CAACF,OAAO,IAAIA,OAAO,KAAK,WAAW,GAAG,EAAE,GAAGA;IAC5D,CAAC,CACJ,CAAC;IAEF,IAAI,CAACzB,aAAa,CAAC6B,IAAI,CAAC,mCAAmC,CAAC;EAChE;AACJ;AAEA,OAAO,MAAMC,wBAAwB,GAAG9C,oBAAoB,CAAC;EACzD+C,WAAW,EAAE9C,wBAAwB;EACrC+C,cAAc,EAAEnC,+BAA+B;EAC/CoC,YAAY,EAAE,CAAC/C,MAAM,EAAEC,aAAa,EAAEC,uBAAuB;AACjE,CAAC,CAAC","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["createImplementation","ProjectInfoService","GetIsCiService","GetNpmVersionService","GetNpxVersionService","GetPulumiVersionService","GetYarnVersionService","GetProjectVersionService","DefaultProjectInfoService","constructor","getIsCi","getNpmVersion","getNpxVersion","getPulumiVersion","getYarnVersion","getProjectVersion","execute","wcpProjectId","process","env","WEBINY_PROJECT_ID","WCP_PROJECT_ID","wcpUsingProjectEnvironmentApiKey","Boolean","WEBINY_PROJECT_API_KEY","WCP_PROJECT_ENVIRONMENT_API_KEY","WCP_ENVIRONMENT_API_KEY","isCI","npmVersion","npxVersion","yarnVersion","pulumiVersion","pulumiAwsVersion","webiny","version","debugEnabled","DEBUG","featureFlags","WEBINY_FEATURE_FLAGS","wcp","projectId","usingProjectEnvironmentApiKey","host","os","platform","arch","nodeJs","npm","npx","yarn","pulumi","secretsProvider","PULUMI_SECRETS_PROVIDER","usingPassword","PULUMI_CONFIG_PASSPHRASE","projectInfoService","abstraction","implementation","dependencies"],"sources":["ProjectInfoService.ts"],"sourcesContent":["import { createImplementation } from \"@webiny/di\";\nimport {\n ProjectInfoService,\n GetIsCiService,\n GetNpmVersionService,\n GetNpxVersionService,\n GetPulumiVersionService,\n GetYarnVersionService,\n GetProjectVersionService\n} from \"~/abstractions/index.js\";\nimport { IProjectInfoServiceResult } from \"~/abstractions/services/ProjectInfoService/ProjectInfoService.js\";\n\nexport class DefaultProjectInfoService implements ProjectInfoService.Interface {\n constructor(\n private getIsCi: GetIsCiService.Interface,\n private getNpmVersion: GetNpmVersionService.Interface,\n private getNpxVersion: GetNpxVersionService.Interface,\n private getPulumiVersion: GetPulumiVersionService.Interface,\n private getYarnVersion: GetYarnVersionService.Interface,\n private getProjectVersion: GetProjectVersionService.Interface\n ) {}\n\n async execute() {\n const wcpProjectId = process.env.WEBINY_PROJECT_ID || process.env.WCP_PROJECT_ID || \"\";\n // const wcpUser = await getUser().catch(() => null);\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n const wcpUsingProjectEnvironmentApiKey = Boolean(\n process.env.WEBINY_PROJECT_API_KEY ||\n
|
|
1
|
+
{"version":3,"names":["createImplementation","ProjectInfoService","GetIsCiService","GetNpmVersionService","GetNpxVersionService","GetPulumiVersionService","GetYarnVersionService","GetProjectVersionService","DefaultProjectInfoService","constructor","getIsCi","getNpmVersion","getNpxVersion","getPulumiVersion","getYarnVersion","getProjectVersion","execute","wcpProjectId","process","env","WEBINY_PROJECT_ID","WCP_PROJECT_ID","wcpUsingProjectEnvironmentApiKey","Boolean","WEBINY_PROJECT_API_KEY","WCP_PROJECT_ENVIRONMENT_API_KEY","WCP_ENVIRONMENT_API_KEY","isCI","npmVersion","npxVersion","yarnVersion","pulumiVersion","pulumiAwsVersion","webiny","version","debugEnabled","DEBUG","featureFlags","WEBINY_FEATURE_FLAGS","wcp","projectId","usingProjectEnvironmentApiKey","host","os","platform","arch","nodeJs","npm","npx","yarn","pulumi","secretsProvider","PULUMI_SECRETS_PROVIDER","usingPassword","PULUMI_CONFIG_PASSPHRASE","projectInfoService","abstraction","implementation","dependencies"],"sources":["ProjectInfoService.ts"],"sourcesContent":["import { createImplementation } from \"@webiny/di\";\nimport {\n ProjectInfoService,\n GetIsCiService,\n GetNpmVersionService,\n GetNpxVersionService,\n GetPulumiVersionService,\n GetYarnVersionService,\n GetProjectVersionService\n} from \"~/abstractions/index.js\";\nimport { IProjectInfoServiceResult } from \"~/abstractions/services/ProjectInfoService/ProjectInfoService.js\";\n\nexport class DefaultProjectInfoService implements ProjectInfoService.Interface {\n constructor(\n private getIsCi: GetIsCiService.Interface,\n private getNpmVersion: GetNpmVersionService.Interface,\n private getNpxVersion: GetNpxVersionService.Interface,\n private getPulumiVersion: GetPulumiVersionService.Interface,\n private getYarnVersion: GetYarnVersionService.Interface,\n private getProjectVersion: GetProjectVersionService.Interface\n ) {}\n\n async execute() {\n const wcpProjectId = process.env.WEBINY_PROJECT_ID || process.env.WCP_PROJECT_ID || \"\";\n // const wcpUser = await getUser().catch(() => null);\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n const wcpUsingProjectEnvironmentApiKey = Boolean(\n process.env.WEBINY_PROJECT_API_KEY ||\n process.env.WCP_PROJECT_ENVIRONMENT_API_KEY ||\n process.env.WCP_ENVIRONMENT_API_KEY\n );\n\n const isCI = this.getIsCi.execute();\n const npmVersion = this.getNpmVersion.execute();\n const npxVersion = this.getNpxVersion.execute();\n const yarnVersion = this.getYarnVersion.execute();\n const [pulumiVersion, pulumiAwsVersion] = this.getPulumiVersion.execute();\n\n return {\n webiny: {\n version: this.getProjectVersion.execute(),\n debugEnabled: process.env.DEBUG === \"true\",\n featureFlags: process.env.WEBINY_FEATURE_FLAGS || {}\n },\n wcp: {\n projectId: wcpProjectId,\n // user: wcpUser?.email || \"N/A\",\n usingProjectEnvironmentApiKey: false // wcpUsingProject\n },\n host: {\n os: `${process.platform} (${process.arch})`,\n nodeJs: process.version,\n npm: npmVersion,\n npx: npxVersion,\n yarn: yarnVersion,\n isCI: isCI\n },\n pulumi: {\n \"@pulumi/pulumi\": pulumiVersion,\n \"@pulumi/aws\": pulumiAwsVersion,\n secretsProvider: process.env.PULUMI_SECRETS_PROVIDER || \"\",\n usingPassword: !!process.env.PULUMI_CONFIG_PASSPHRASE\n }\n } as IProjectInfoServiceResult;\n }\n}\n\nexport const projectInfoService = createImplementation({\n abstraction: ProjectInfoService,\n implementation: DefaultProjectInfoService,\n dependencies: [\n GetIsCiService,\n GetNpmVersionService,\n GetNpxVersionService,\n GetPulumiVersionService,\n GetYarnVersionService,\n GetProjectVersionService\n ]\n});\n"],"mappings":"AAAA,SAASA,oBAAoB,QAAQ,YAAY;AACjD,SACIC,kBAAkB,EAClBC,cAAc,EACdC,oBAAoB,EACpBC,oBAAoB,EACpBC,uBAAuB,EACvBC,qBAAqB,EACrBC,wBAAwB;AAI5B,OAAO,MAAMC,yBAAyB,CAAyC;EAC3EC,WAAWA,CACCC,OAAiC,EACjCC,aAA6C,EAC7CC,aAA6C,EAC7CC,gBAAmD,EACnDC,cAA+C,EAC/CC,iBAAqD,EAC/D;IAAA,KANUL,OAAiC,GAAjCA,OAAiC;IAAA,KACjCC,aAA6C,GAA7CA,aAA6C;IAAA,KAC7CC,aAA6C,GAA7CA,aAA6C;IAAA,KAC7CC,gBAAmD,GAAnDA,gBAAmD;IAAA,KACnDC,cAA+C,GAA/CA,cAA+C;IAAA,KAC/CC,iBAAqD,GAArDA,iBAAqD;EAC9D;EAEH,MAAMC,OAAOA,CAAA,EAAG;IACZ,MAAMC,YAAY,GAAGC,OAAO,CAACC,GAAG,CAACC,iBAAiB,IAAIF,OAAO,CAACC,GAAG,CAACE,cAAc,IAAI,EAAE;IACtF;IACA;IACA,MAAMC,gCAAgC,GAAGC,OAAO,CAC5CL,OAAO,CAACC,GAAG,CAACK,sBAAsB,IAClCN,OAAO,CAACC,GAAG,CAACM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