@phila/cli 0.0.1
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/commands/config.d.ts +30 -0
- package/dist/commands/config.d.ts.map +1 -0
- package/dist/commands/config.js +135 -0
- package/dist/commands/config.js.map +1 -0
- package/dist/commands/deploy.d.ts +2 -0
- package/dist/commands/deploy.d.ts.map +1 -0
- package/dist/commands/deploy.js +224 -0
- package/dist/commands/deploy.js.map +1 -0
- package/dist/commands/destroy.d.ts +3 -0
- package/dist/commands/destroy.d.ts.map +1 -0
- package/dist/commands/destroy.js +110 -0
- package/dist/commands/destroy.js.map +1 -0
- package/dist/commands/init.d.ts +25 -0
- package/dist/commands/init.d.ts.map +1 -0
- package/dist/commands/init.js +513 -0
- package/dist/commands/init.js.map +1 -0
- package/dist/commands/map.d.ts +8 -0
- package/dist/commands/map.d.ts.map +1 -0
- package/dist/commands/map.js +186 -0
- package/dist/commands/map.js.map +1 -0
- package/dist/commands/ship.d.ts +20 -0
- package/dist/commands/ship.d.ts.map +1 -0
- package/dist/commands/ship.js +445 -0
- package/dist/commands/ship.js.map +1 -0
- package/dist/commands/templates.d.ts +3 -0
- package/dist/commands/templates.d.ts.map +1 -0
- package/dist/commands/templates.js +120 -0
- package/dist/commands/templates.js.map +1 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +82 -0
- package/dist/index.js.map +1 -0
- package/dist/templates/_shared/city.config.json.tmpl +24 -0
- package/dist/templates/_shared/dotnet-api/Api.csproj +17 -0
- package/dist/templates/_shared/dotnet-api/Program.cs +58 -0
- package/dist/templates/_shared/dotnet-api/aws-lambda-tools-defaults.json +10 -0
- package/dist/templates/_shared/dotnet-api/obj/Api.csproj.nuget.dgspec.json +80 -0
- package/dist/templates/_shared/dotnet-api/obj/Api.csproj.nuget.g.props +15 -0
- package/dist/templates/_shared/dotnet-api/obj/Api.csproj.nuget.g.targets +2 -0
- package/dist/templates/_shared/dotnet-api/obj/Debug/net8.0/.NETCoreApp,Version=v8.0.AssemblyAttributes.cs +4 -0
- package/dist/templates/_shared/dotnet-api/obj/Debug/net8.0/Api.AssemblyInfo.cs +22 -0
- package/dist/templates/_shared/dotnet-api/obj/Debug/net8.0/Api.AssemblyInfoInputs.cache +1 -0
- package/dist/templates/_shared/dotnet-api/obj/Debug/net8.0/Api.GeneratedMSBuildEditorConfig.editorconfig +19 -0
- package/dist/templates/_shared/dotnet-api/obj/Debug/net8.0/Api.GlobalUsings.g.cs +17 -0
- package/dist/templates/_shared/dotnet-api/obj/Debug/net8.0/Api.assets.cache +0 -0
- package/dist/templates/_shared/dotnet-api/obj/Debug/net8.0/Api.csproj.AssemblyReference.cache +0 -0
- package/dist/templates/_shared/dotnet-api/obj/project.assets.json +708 -0
- package/dist/templates/_shared/dotnet-api/obj/project.nuget.cache +35 -0
- package/dist/templates/_shared/dotnet-api-postgres/Api.csproj +19 -0
- package/dist/templates/_shared/dotnet-api-postgres/Program.cs +167 -0
- package/dist/templates/_shared/dotnet-api-postgres/aws-lambda-tools-defaults.json +10 -0
- package/dist/templates/_shared/dotnet-api-postgres/obj/Api.csproj.nuget.dgspec.json +88 -0
- package/dist/templates/_shared/dotnet-api-postgres/obj/Api.csproj.nuget.g.props +15 -0
- package/dist/templates/_shared/dotnet-api-postgres/obj/Api.csproj.nuget.g.targets +2 -0
- package/dist/templates/_shared/dotnet-api-postgres/obj/Debug/net8.0/.NETCoreApp,Version=v8.0.AssemblyAttributes.cs +4 -0
- package/dist/templates/_shared/dotnet-api-postgres/obj/Debug/net8.0/Api.AssemblyInfo.cs +22 -0
- package/dist/templates/_shared/dotnet-api-postgres/obj/Debug/net8.0/Api.AssemblyInfoInputs.cache +1 -0
- package/dist/templates/_shared/dotnet-api-postgres/obj/Debug/net8.0/Api.GeneratedMSBuildEditorConfig.editorconfig +19 -0
- package/dist/templates/_shared/dotnet-api-postgres/obj/Debug/net8.0/Api.GlobalUsings.g.cs +17 -0
- package/dist/templates/_shared/dotnet-api-postgres/obj/Debug/net8.0/Api.assets.cache +0 -0
- package/dist/templates/_shared/dotnet-api-postgres/obj/project.assets.json +106 -0
- package/dist/templates/_shared/dotnet-api-postgres/obj/project.nuget.cache +15 -0
- package/dist/templates/_shared/nuxt-frontend/app.vue +3 -0
- package/dist/templates/_shared/nuxt-frontend/nuxt.config.ts +25 -0
- package/dist/templates/_shared/nuxt-frontend/package.json.tmpl +19 -0
- package/dist/templates/_shared/nuxt-frontend/pages/index.vue +6 -0
- package/dist/templates/_shared/nuxt-frontend/public/.gitkeep +0 -0
- package/dist/templates/_shared/nuxt-frontend/tsconfig.json +3 -0
- package/dist/templates/_shared/webapp-cdk-package.json.tmpl +23 -0
- package/dist/templates/_shared/webapp-frontend/app.vue +3 -0
- package/dist/templates/_shared/webapp-frontend/nuxt.config.ts +25 -0
- package/dist/templates/_shared/webapp-frontend/package.json.tmpl +19 -0
- package/dist/templates/_shared/webapp-frontend/pages/index.vue +7 -0
- package/dist/templates/_shared/webapp-frontend/public/.gitkeep +0 -0
- package/dist/templates/_shared/webapp-frontend/tsconfig.json +3 -0
- package/dist/templates/lambda-api-nodejs/README.md.tmpl +203 -0
- package/dist/templates/lambda-api-nodejs/apps/__lambdaName__/index.ts +89 -0
- package/dist/templates/lambda-api-nodejs/apps/__lambdaName__/package.json +17 -0
- package/dist/templates/lambda-api-nodejs/apps/__lambdaName__/tsconfig.json +8 -0
- package/dist/templates/lambda-api-nodejs/cdk/app.ts.tmpl +53 -0
- package/dist/templates/lambda-api-nodejs/cdk/cdk.json +68 -0
- package/dist/templates/lambda-api-nodejs/cdk/package.json +23 -0
- package/dist/templates/lambda-api-nodejs/cdk/tsconfig.json +9 -0
- package/dist/templates/lambda-api-nodejs/package.json.tmpl +20 -0
- package/dist/templates/lambda-api-nodejs/tsconfig.json +27 -0
- package/dist/templates/lambda-dynamo-api/README.md.tmpl +184 -0
- package/dist/templates/lambda-dynamo-api/apps/__lambdaName__/index.ts +109 -0
- package/dist/templates/lambda-dynamo-api/apps/__lambdaName__/package.json +19 -0
- package/dist/templates/lambda-dynamo-api/apps/__lambdaName__/tsconfig.json +24 -0
- package/dist/templates/lambda-dynamo-api/cdk/app.ts.tmpl +59 -0
- package/dist/templates/lambda-dynamo-api/cdk/cdk.json +73 -0
- package/dist/templates/lambda-dynamo-api/cdk/package.json +23 -0
- package/dist/templates/lambda-dynamo-api/cdk/tsconfig.json +14 -0
- package/dist/templates/lambda-dynamo-api/package.json.tmpl +20 -0
- package/dist/templates/lambda-dynamo-api/tsconfig.json +27 -0
- package/dist/templates/lambda-postgres-api/README.md.tmpl +234 -0
- package/dist/templates/lambda-postgres-api/apps/__lambdaName__/index.ts +76 -0
- package/dist/templates/lambda-postgres-api/apps/__lambdaName__/package.json +18 -0
- package/dist/templates/lambda-postgres-api/apps/__lambdaName__/tsconfig.json +26 -0
- package/dist/templates/lambda-postgres-api/cdk/app.ts.tmpl +55 -0
- package/dist/templates/lambda-postgres-api/cdk/cdk.json +4 -0
- package/dist/templates/lambda-postgres-api/cdk/package.json +23 -0
- package/dist/templates/lambda-postgres-api/cdk/tsconfig.json +25 -0
- package/dist/templates/lambda-postgres-api/package.json.tmpl +20 -0
- package/dist/templates/lambda-postgres-api/tsconfig.json +11 -0
- package/dist/templates/static-site/README.md.tmpl +72 -0
- package/dist/templates/static-site/cdk/app.ts.tmpl +50 -0
- package/dist/templates/static-site/cdk/cdk.json +68 -0
- package/dist/templates/static-site/cdk/package.json +23 -0
- package/dist/templates/static-site/cdk/tsconfig.json +9 -0
- package/dist/templates/static-site/frontend/.gitkeep +0 -0
- package/dist/templates/static-site/frontend/README.md +41 -0
- package/dist/templates/static-site/frontend/package.json +9 -0
- package/dist/templates/static-site/package.json.tmpl +19 -0
- package/dist/templates/static-site/tsconfig.json +27 -0
- package/dist/templates/webapp-ecs-dotnet/README.md.tmpl +213 -0
- package/dist/templates/webapp-ecs-dotnet/apps/api/Api.csproj +12 -0
- package/dist/templates/webapp-ecs-dotnet/apps/api/Dockerfile +30 -0
- package/dist/templates/webapp-ecs-dotnet/apps/api/Program.cs +85 -0
- package/dist/templates/webapp-ecs-dotnet/apps/api/obj/Api.csproj.nuget.dgspec.json +70 -0
- package/dist/templates/webapp-ecs-dotnet/apps/api/obj/Api.csproj.nuget.g.props +15 -0
- package/dist/templates/webapp-ecs-dotnet/apps/api/obj/Api.csproj.nuget.g.targets +2 -0
- package/dist/templates/webapp-ecs-dotnet/apps/api/obj/Debug/net8.0/.NETCoreApp,Version=v8.0.AssemblyAttributes.cs +4 -0
- package/dist/templates/webapp-ecs-dotnet/apps/api/obj/Debug/net8.0/Api.AssemblyInfo.cs +22 -0
- package/dist/templates/webapp-ecs-dotnet/apps/api/obj/Debug/net8.0/Api.AssemblyInfoInputs.cache +1 -0
- package/dist/templates/webapp-ecs-dotnet/apps/api/obj/Debug/net8.0/Api.GeneratedMSBuildEditorConfig.editorconfig +19 -0
- package/dist/templates/webapp-ecs-dotnet/apps/api/obj/Debug/net8.0/Api.GlobalUsings.g.cs +17 -0
- package/dist/templates/webapp-ecs-dotnet/apps/api/obj/Debug/net8.0/Api.assets.cache +0 -0
- package/dist/templates/webapp-ecs-dotnet/apps/api/obj/project.assets.json +75 -0
- package/dist/templates/webapp-ecs-dotnet/apps/api/obj/project.nuget.cache +8 -0
- package/dist/templates/webapp-ecs-dotnet/cdk/app.ts.tmpl +60 -0
- package/dist/templates/webapp-ecs-dotnet/cdk/cdk.json +38 -0
- package/dist/templates/webapp-ecs-dotnet/cdk/tsconfig.json +25 -0
- package/dist/templates/webapp-ecs-dotnet/package.json.tmpl +23 -0
- package/dist/templates/webapp-ecs-dotnet/tsconfig.json +26 -0
- package/dist/templates/webapp-ecs-node/README.md.tmpl +207 -0
- package/dist/templates/webapp-ecs-node/apps/api/Dockerfile +33 -0
- package/dist/templates/webapp-ecs-node/apps/api/index.ts +74 -0
- package/dist/templates/webapp-ecs-node/apps/api/package.json +22 -0
- package/dist/templates/webapp-ecs-node/apps/api/tsconfig.json +18 -0
- package/dist/templates/webapp-ecs-node/cdk/app.ts.tmpl +60 -0
- package/dist/templates/webapp-ecs-node/cdk/cdk.json +38 -0
- package/dist/templates/webapp-ecs-node/cdk/tsconfig.json +25 -0
- package/dist/templates/webapp-ecs-node/package.json.tmpl +25 -0
- package/dist/templates/webapp-ecs-node/tsconfig.json +26 -0
- package/dist/templates/webapp-ecs-postgres-dotnet/README.md.tmpl +271 -0
- package/dist/templates/webapp-ecs-postgres-dotnet/apps/api/Api.csproj +17 -0
- package/dist/templates/webapp-ecs-postgres-dotnet/apps/api/Dockerfile +30 -0
- package/dist/templates/webapp-ecs-postgres-dotnet/apps/api/Program.cs +194 -0
- package/dist/templates/webapp-ecs-postgres-dotnet/apps/api/obj/Api.csproj.nuget.dgspec.json +80 -0
- package/dist/templates/webapp-ecs-postgres-dotnet/apps/api/obj/Api.csproj.nuget.g.props +19 -0
- package/dist/templates/webapp-ecs-postgres-dotnet/apps/api/obj/Api.csproj.nuget.g.targets +6 -0
- package/dist/templates/webapp-ecs-postgres-dotnet/apps/api/obj/Debug/net8.0/.NETCoreApp,Version=v8.0.AssemblyAttributes.cs +4 -0
- package/dist/templates/webapp-ecs-postgres-dotnet/apps/api/obj/Debug/net8.0/Api.AssemblyInfo.cs +22 -0
- package/dist/templates/webapp-ecs-postgres-dotnet/apps/api/obj/Debug/net8.0/Api.AssemblyInfoInputs.cache +1 -0
- package/dist/templates/webapp-ecs-postgres-dotnet/apps/api/obj/Debug/net8.0/Api.GeneratedMSBuildEditorConfig.editorconfig +19 -0
- package/dist/templates/webapp-ecs-postgres-dotnet/apps/api/obj/Debug/net8.0/Api.GlobalUsings.g.cs +17 -0
- package/dist/templates/webapp-ecs-postgres-dotnet/apps/api/obj/Debug/net8.0/Api.assets.cache +0 -0
- package/dist/templates/webapp-ecs-postgres-dotnet/apps/api/obj/Debug/net8.0/Api.csproj.AssemblyReference.cache +0 -0
- package/dist/templates/webapp-ecs-postgres-dotnet/apps/api/obj/project.assets.json +395 -0
- package/dist/templates/webapp-ecs-postgres-dotnet/apps/api/obj/project.nuget.cache +49 -0
- package/dist/templates/webapp-ecs-postgres-dotnet/cdk/app.ts.tmpl +62 -0
- package/dist/templates/webapp-ecs-postgres-dotnet/cdk/cdk.json +38 -0
- package/dist/templates/webapp-ecs-postgres-dotnet/cdk/tsconfig.json +25 -0
- package/dist/templates/webapp-ecs-postgres-dotnet/package.json.tmpl +23 -0
- package/dist/templates/webapp-ecs-postgres-dotnet/tsconfig.json +26 -0
- package/dist/templates/webapp-ecs-postgres-node/README.md.tmpl +261 -0
- package/dist/templates/webapp-ecs-postgres-node/apps/api/Dockerfile +33 -0
- package/dist/templates/webapp-ecs-postgres-node/apps/api/index.ts +160 -0
- package/dist/templates/webapp-ecs-postgres-node/apps/api/package.json +25 -0
- package/dist/templates/webapp-ecs-postgres-node/apps/api/tsconfig.json +18 -0
- package/dist/templates/webapp-ecs-postgres-node/cdk/app.ts.tmpl +62 -0
- package/dist/templates/webapp-ecs-postgres-node/cdk/cdk.json +38 -0
- package/dist/templates/webapp-ecs-postgres-node/cdk/tsconfig.json +25 -0
- package/dist/templates/webapp-ecs-postgres-node/package.json.tmpl +25 -0
- package/dist/templates/webapp-ecs-postgres-node/tsconfig.json +26 -0
- package/dist/templates/webapp-lambda-dotnet/README.md.tmpl +188 -0
- package/dist/templates/webapp-lambda-dotnet/apps/api/Api.csproj +17 -0
- package/dist/templates/webapp-lambda-dotnet/apps/api/Program.cs +58 -0
- package/dist/templates/webapp-lambda-dotnet/apps/api/aws-lambda-tools-defaults.json +10 -0
- package/dist/templates/webapp-lambda-dotnet/apps/api/obj/Api.csproj.nuget.dgspec.json +80 -0
- package/dist/templates/webapp-lambda-dotnet/apps/api/obj/Api.csproj.nuget.g.props +15 -0
- package/dist/templates/webapp-lambda-dotnet/apps/api/obj/Api.csproj.nuget.g.targets +2 -0
- package/dist/templates/webapp-lambda-dotnet/apps/api/obj/Debug/net8.0/.NETCoreApp,Version=v8.0.AssemblyAttributes.cs +4 -0
- package/dist/templates/webapp-lambda-dotnet/apps/api/obj/Debug/net8.0/Api.AssemblyInfo.cs +22 -0
- package/dist/templates/webapp-lambda-dotnet/apps/api/obj/Debug/net8.0/Api.AssemblyInfoInputs.cache +1 -0
- package/dist/templates/webapp-lambda-dotnet/apps/api/obj/Debug/net8.0/Api.GeneratedMSBuildEditorConfig.editorconfig +19 -0
- package/dist/templates/webapp-lambda-dotnet/apps/api/obj/Debug/net8.0/Api.GlobalUsings.g.cs +17 -0
- package/dist/templates/webapp-lambda-dotnet/apps/api/obj/Debug/net8.0/Api.assets.cache +0 -0
- package/dist/templates/webapp-lambda-dotnet/apps/api/obj/Debug/net8.0/Api.csproj.AssemblyReference.cache +0 -0
- package/dist/templates/webapp-lambda-dotnet/apps/api/obj/project.assets.json +708 -0
- package/dist/templates/webapp-lambda-dotnet/apps/api/obj/project.nuget.cache +35 -0
- package/dist/templates/webapp-lambda-dotnet/cdk/app.ts.tmpl +59 -0
- package/dist/templates/webapp-lambda-dotnet/cdk/cdk.json +68 -0
- package/dist/templates/webapp-lambda-dotnet/cdk/tsconfig.json +9 -0
- package/dist/templates/webapp-lambda-dotnet/package.json.tmpl +23 -0
- package/dist/templates/webapp-lambda-dotnet/tsconfig.json +27 -0
- package/dist/templates/webapp-lambda-dynamo-dotnet/README.md.tmpl +223 -0
- package/dist/templates/webapp-lambda-dynamo-dotnet/apps/api/Api.csproj +18 -0
- package/dist/templates/webapp-lambda-dynamo-dotnet/apps/api/Program.cs +155 -0
- package/dist/templates/webapp-lambda-dynamo-dotnet/apps/api/aws-lambda-tools-defaults.json +10 -0
- package/dist/templates/webapp-lambda-dynamo-dotnet/apps/api/obj/Api.csproj.nuget.dgspec.json +84 -0
- package/dist/templates/webapp-lambda-dynamo-dotnet/apps/api/obj/Api.csproj.nuget.g.props +19 -0
- package/dist/templates/webapp-lambda-dynamo-dotnet/apps/api/obj/Api.csproj.nuget.g.targets +2 -0
- package/dist/templates/webapp-lambda-dynamo-dotnet/apps/api/obj/Debug/net8.0/.NETCoreApp,Version=v8.0.AssemblyAttributes.cs +4 -0
- package/dist/templates/webapp-lambda-dynamo-dotnet/apps/api/obj/Debug/net8.0/Api.AssemblyInfo.cs +22 -0
- package/dist/templates/webapp-lambda-dynamo-dotnet/apps/api/obj/Debug/net8.0/Api.AssemblyInfoInputs.cache +1 -0
- package/dist/templates/webapp-lambda-dynamo-dotnet/apps/api/obj/Debug/net8.0/Api.GeneratedMSBuildEditorConfig.editorconfig +19 -0
- package/dist/templates/webapp-lambda-dynamo-dotnet/apps/api/obj/Debug/net8.0/Api.GlobalUsings.g.cs +17 -0
- package/dist/templates/webapp-lambda-dynamo-dotnet/apps/api/obj/Debug/net8.0/Api.assets.cache +0 -0
- package/dist/templates/webapp-lambda-dynamo-dotnet/apps/api/obj/Debug/net8.0/Api.csproj.AssemblyReference.cache +0 -0
- package/dist/templates/webapp-lambda-dynamo-dotnet/apps/api/obj/project.assets.json +989 -0
- package/dist/templates/webapp-lambda-dynamo-dotnet/apps/api/obj/project.nuget.cache +223 -0
- package/dist/templates/webapp-lambda-dynamo-dotnet/cdk/app.ts.tmpl +65 -0
- package/dist/templates/webapp-lambda-dynamo-dotnet/cdk/cdk.json +68 -0
- package/dist/templates/webapp-lambda-dynamo-dotnet/cdk/tsconfig.json +9 -0
- package/dist/templates/webapp-lambda-dynamo-dotnet/package.json.tmpl +23 -0
- package/dist/templates/webapp-lambda-dynamo-dotnet/tsconfig.json +27 -0
- package/dist/templates/webapp-lambda-dynamo-node/README.md.tmpl +189 -0
- package/dist/templates/webapp-lambda-dynamo-node/apps/api/index.ts +109 -0
- package/dist/templates/webapp-lambda-dynamo-node/apps/api/package.json +19 -0
- package/dist/templates/webapp-lambda-dynamo-node/apps/api/tsconfig.json +8 -0
- package/dist/templates/webapp-lambda-dynamo-node/cdk/app.ts.tmpl +65 -0
- package/dist/templates/webapp-lambda-dynamo-node/cdk/cdk.json +68 -0
- package/dist/templates/webapp-lambda-dynamo-node/cdk/tsconfig.json +9 -0
- package/dist/templates/webapp-lambda-dynamo-node/package.json.tmpl +24 -0
- package/dist/templates/webapp-lambda-dynamo-node/tsconfig.json +27 -0
- package/dist/templates/webapp-lambda-node/README.md.tmpl +179 -0
- package/dist/templates/webapp-lambda-node/apps/api/index.ts +100 -0
- package/dist/templates/webapp-lambda-node/apps/api/package.json +17 -0
- package/dist/templates/webapp-lambda-node/apps/api/tsconfig.json +8 -0
- package/dist/templates/webapp-lambda-node/cdk/app.ts.tmpl +59 -0
- package/dist/templates/webapp-lambda-node/cdk/cdk.json +68 -0
- package/dist/templates/webapp-lambda-node/cdk/tsconfig.json +9 -0
- package/dist/templates/webapp-lambda-node/package.json.tmpl +24 -0
- package/dist/templates/webapp-lambda-node/tsconfig.json +27 -0
- package/dist/templates/webapp-lambda-postgres-dotnet/README.md.tmpl +240 -0
- package/dist/templates/webapp-lambda-postgres-dotnet/apps/api/Api.csproj +19 -0
- package/dist/templates/webapp-lambda-postgres-dotnet/apps/api/Program.cs +167 -0
- package/dist/templates/webapp-lambda-postgres-dotnet/apps/api/aws-lambda-tools-defaults.json +10 -0
- package/dist/templates/webapp-lambda-postgres-dotnet/apps/api/obj/Api.csproj.nuget.dgspec.json +88 -0
- package/dist/templates/webapp-lambda-postgres-dotnet/apps/api/obj/Api.csproj.nuget.g.props +15 -0
- package/dist/templates/webapp-lambda-postgres-dotnet/apps/api/obj/Api.csproj.nuget.g.targets +2 -0
- package/dist/templates/webapp-lambda-postgres-dotnet/apps/api/obj/Debug/net8.0/.NETCoreApp,Version=v8.0.AssemblyAttributes.cs +4 -0
- package/dist/templates/webapp-lambda-postgres-dotnet/apps/api/obj/Debug/net8.0/Api.AssemblyInfo.cs +22 -0
- package/dist/templates/webapp-lambda-postgres-dotnet/apps/api/obj/Debug/net8.0/Api.AssemblyInfoInputs.cache +1 -0
- package/dist/templates/webapp-lambda-postgres-dotnet/apps/api/obj/Debug/net8.0/Api.GeneratedMSBuildEditorConfig.editorconfig +19 -0
- package/dist/templates/webapp-lambda-postgres-dotnet/apps/api/obj/Debug/net8.0/Api.GlobalUsings.g.cs +17 -0
- package/dist/templates/webapp-lambda-postgres-dotnet/apps/api/obj/Debug/net8.0/Api.assets.cache +0 -0
- package/dist/templates/webapp-lambda-postgres-dotnet/apps/api/obj/project.assets.json +106 -0
- package/dist/templates/webapp-lambda-postgres-dotnet/apps/api/obj/project.nuget.cache +15 -0
- package/dist/templates/webapp-lambda-postgres-dotnet/cdk/app.ts.tmpl +61 -0
- package/dist/templates/webapp-lambda-postgres-dotnet/cdk/cdk.json +68 -0
- package/dist/templates/webapp-lambda-postgres-dotnet/cdk/tsconfig.json +9 -0
- package/dist/templates/webapp-lambda-postgres-dotnet/package.json.tmpl +23 -0
- package/dist/templates/webapp-lambda-postgres-dotnet/tsconfig.json +27 -0
- package/dist/templates/webapp-lambda-postgres-node/README.md.tmpl +190 -0
- package/dist/templates/webapp-lambda-postgres-node/apps/api/index.ts +76 -0
- package/dist/templates/webapp-lambda-postgres-node/apps/api/package.json +18 -0
- package/dist/templates/webapp-lambda-postgres-node/apps/api/tsconfig.json +8 -0
- package/dist/templates/webapp-lambda-postgres-node/cdk/app.ts.tmpl +61 -0
- package/dist/templates/webapp-lambda-postgres-node/cdk/cdk.json +68 -0
- package/dist/templates/webapp-lambda-postgres-node/cdk/tsconfig.json +9 -0
- package/dist/templates/webapp-lambda-postgres-node/package.json.tmpl +24 -0
- package/dist/templates/webapp-lambda-postgres-node/tsconfig.json +27 -0
- package/dist/utils/aws.d.ts +4 -0
- package/dist/utils/aws.d.ts.map +1 -0
- package/dist/utils/aws.js +90 -0
- package/dist/utils/aws.js.map +1 -0
- package/dist/utils/dependencies.d.ts +27 -0
- package/dist/utils/dependencies.d.ts.map +1 -0
- package/dist/utils/dependencies.js +267 -0
- package/dist/utils/dependencies.js.map +1 -0
- package/dist/utils/template.d.ts +23 -0
- package/dist/utils/template.d.ts.map +1 -0
- package/dist/utils/template.js +115 -0
- package/dist/utils/template.js.map +1 -0
- package/package.json +48 -0
|
@@ -0,0 +1,267 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// ABOUTME: Dependency validation and auto-installation for CLI tools
|
|
3
|
+
// ABOUTME: Checks node, npm, pnpm, aws, cdk, zip on every command
|
|
4
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
5
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
6
|
+
};
|
|
7
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8
|
+
exports.DEPENDENCIES = exports.Platform = void 0;
|
|
9
|
+
exports.getPlatform = getPlatform;
|
|
10
|
+
exports.checkAllDependencies = checkAllDependencies;
|
|
11
|
+
exports.ensureDependencies = ensureDependencies;
|
|
12
|
+
const child_process_1 = require("child_process");
|
|
13
|
+
const os_1 = require("os");
|
|
14
|
+
const chalk_1 = __importDefault(require("chalk"));
|
|
15
|
+
const inquirer_1 = __importDefault(require("inquirer"));
|
|
16
|
+
var Platform;
|
|
17
|
+
(function (Platform) {
|
|
18
|
+
Platform["Darwin"] = "darwin";
|
|
19
|
+
Platform["Linux"] = "linux";
|
|
20
|
+
Platform["Win32"] = "win32";
|
|
21
|
+
})(Platform || (exports.Platform = Platform = {}));
|
|
22
|
+
function getPlatform() {
|
|
23
|
+
const p = (0, os_1.platform)();
|
|
24
|
+
if (p === 'darwin')
|
|
25
|
+
return Platform.Darwin;
|
|
26
|
+
if (p === 'win32')
|
|
27
|
+
return Platform.Win32;
|
|
28
|
+
return Platform.Linux;
|
|
29
|
+
}
|
|
30
|
+
exports.DEPENDENCIES = [
|
|
31
|
+
{
|
|
32
|
+
name: 'node',
|
|
33
|
+
check: async () => {
|
|
34
|
+
try {
|
|
35
|
+
const version = (0, child_process_1.execSync)('node --version').toString().trim();
|
|
36
|
+
const major = parseInt(version.slice(1).split('.')[0]);
|
|
37
|
+
return { name: 'node', installed: major >= 18, version };
|
|
38
|
+
}
|
|
39
|
+
catch {
|
|
40
|
+
return { name: 'node', installed: false };
|
|
41
|
+
}
|
|
42
|
+
},
|
|
43
|
+
install: {
|
|
44
|
+
[Platform.Darwin]: async () => {
|
|
45
|
+
(0, child_process_1.execSync)('curl -fsSL https://fnm.vercel.app/install | bash', { stdio: 'inherit' });
|
|
46
|
+
(0, child_process_1.execSync)('fnm install 20', { stdio: 'inherit' });
|
|
47
|
+
return true;
|
|
48
|
+
},
|
|
49
|
+
[Platform.Linux]: async () => {
|
|
50
|
+
(0, child_process_1.execSync)('curl -fsSL https://fnm.vercel.app/install | bash', { stdio: 'inherit' });
|
|
51
|
+
(0, child_process_1.execSync)('fnm install 20', { stdio: 'inherit' });
|
|
52
|
+
return true;
|
|
53
|
+
},
|
|
54
|
+
[Platform.Win32]: async () => {
|
|
55
|
+
(0, child_process_1.execSync)(`powershell -Command "Invoke-WebRequest -Uri 'https://nodejs.org/dist/v20.10.0/node-v20.10.0-x64.msi' -OutFile '$env:TEMP\\node.msi'; Start-Process msiexec -ArgumentList '/i', '$env:TEMP\\node.msi', '/quiet' -Wait"`, { stdio: 'inherit' });
|
|
56
|
+
return true;
|
|
57
|
+
},
|
|
58
|
+
},
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
name: 'npm',
|
|
62
|
+
check: async () => {
|
|
63
|
+
try {
|
|
64
|
+
const version = (0, child_process_1.execSync)('npm --version').toString().trim();
|
|
65
|
+
return { name: 'npm', installed: true, version };
|
|
66
|
+
}
|
|
67
|
+
catch {
|
|
68
|
+
return { name: 'npm', installed: false };
|
|
69
|
+
}
|
|
70
|
+
},
|
|
71
|
+
instructions: {
|
|
72
|
+
[Platform.Darwin]: 'npm is included with Node.js. Install Node first.',
|
|
73
|
+
[Platform.Linux]: 'npm is included with Node.js. Install Node first.',
|
|
74
|
+
[Platform.Win32]: 'npm is included with Node.js. Install Node first.',
|
|
75
|
+
},
|
|
76
|
+
},
|
|
77
|
+
{
|
|
78
|
+
name: 'pnpm',
|
|
79
|
+
check: async () => {
|
|
80
|
+
try {
|
|
81
|
+
const version = (0, child_process_1.execSync)('pnpm --version').toString().trim();
|
|
82
|
+
return { name: 'pnpm', installed: true, version };
|
|
83
|
+
}
|
|
84
|
+
catch {
|
|
85
|
+
return { name: 'pnpm', installed: false };
|
|
86
|
+
}
|
|
87
|
+
},
|
|
88
|
+
install: {
|
|
89
|
+
[Platform.Darwin]: async () => {
|
|
90
|
+
(0, child_process_1.execSync)('npm install -g pnpm', { stdio: 'inherit' });
|
|
91
|
+
return true;
|
|
92
|
+
},
|
|
93
|
+
[Platform.Linux]: async () => {
|
|
94
|
+
(0, child_process_1.execSync)('npm install -g pnpm', { stdio: 'inherit' });
|
|
95
|
+
return true;
|
|
96
|
+
},
|
|
97
|
+
[Platform.Win32]: async () => {
|
|
98
|
+
(0, child_process_1.execSync)('npm install -g pnpm', { stdio: 'inherit' });
|
|
99
|
+
return true;
|
|
100
|
+
},
|
|
101
|
+
},
|
|
102
|
+
},
|
|
103
|
+
{
|
|
104
|
+
name: 'aws',
|
|
105
|
+
check: async () => {
|
|
106
|
+
try {
|
|
107
|
+
const output = (0, child_process_1.execSync)('aws --version').toString().trim();
|
|
108
|
+
const version = output.split(' ')[0].replace('aws-cli/', '');
|
|
109
|
+
return { name: 'aws', installed: true, version };
|
|
110
|
+
}
|
|
111
|
+
catch {
|
|
112
|
+
return { name: 'aws', installed: false };
|
|
113
|
+
}
|
|
114
|
+
},
|
|
115
|
+
install: {
|
|
116
|
+
[Platform.Darwin]: async () => {
|
|
117
|
+
(0, child_process_1.execSync)('curl "https://awscli.amazonaws.com/AWSCLIV2.pkg" -o "/tmp/AWSCLIV2.pkg" && sudo installer -pkg /tmp/AWSCLIV2.pkg -target /', { stdio: 'inherit' });
|
|
118
|
+
return true;
|
|
119
|
+
},
|
|
120
|
+
[Platform.Linux]: async () => {
|
|
121
|
+
(0, child_process_1.execSync)('curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "/tmp/awscliv2.zip" && unzip -o /tmp/awscliv2.zip -d /tmp && sudo /tmp/aws/install', { stdio: 'inherit' });
|
|
122
|
+
return true;
|
|
123
|
+
},
|
|
124
|
+
[Platform.Win32]: async () => {
|
|
125
|
+
(0, child_process_1.execSync)(`powershell -Command "Invoke-WebRequest -Uri 'https://awscli.amazonaws.com/AWSCLIV2.msi' -OutFile '$env:TEMP\\AWSCLIV2.msi'; Start-Process msiexec -ArgumentList '/i', '$env:TEMP\\AWSCLIV2.msi', '/quiet' -Wait"`, { stdio: 'inherit' });
|
|
126
|
+
return true;
|
|
127
|
+
},
|
|
128
|
+
},
|
|
129
|
+
},
|
|
130
|
+
{
|
|
131
|
+
name: 'cdk',
|
|
132
|
+
check: async () => {
|
|
133
|
+
try {
|
|
134
|
+
const version = (0, child_process_1.execSync)('cdk --version').toString().trim().split(' ')[0];
|
|
135
|
+
return { name: 'cdk', installed: true, version };
|
|
136
|
+
}
|
|
137
|
+
catch {
|
|
138
|
+
return { name: 'cdk', installed: false };
|
|
139
|
+
}
|
|
140
|
+
},
|
|
141
|
+
install: {
|
|
142
|
+
[Platform.Darwin]: async () => {
|
|
143
|
+
(0, child_process_1.execSync)('npm install -g aws-cdk', { stdio: 'inherit' });
|
|
144
|
+
return true;
|
|
145
|
+
},
|
|
146
|
+
[Platform.Linux]: async () => {
|
|
147
|
+
(0, child_process_1.execSync)('npm install -g aws-cdk', { stdio: 'inherit' });
|
|
148
|
+
return true;
|
|
149
|
+
},
|
|
150
|
+
[Platform.Win32]: async () => {
|
|
151
|
+
(0, child_process_1.execSync)('npm install -g aws-cdk', { stdio: 'inherit' });
|
|
152
|
+
return true;
|
|
153
|
+
},
|
|
154
|
+
},
|
|
155
|
+
},
|
|
156
|
+
{
|
|
157
|
+
name: 'zip',
|
|
158
|
+
check: async () => {
|
|
159
|
+
try {
|
|
160
|
+
(0, child_process_1.execSync)('zip --version', { stdio: 'pipe' });
|
|
161
|
+
return { name: 'zip', installed: true };
|
|
162
|
+
}
|
|
163
|
+
catch {
|
|
164
|
+
return { name: 'zip', installed: false };
|
|
165
|
+
}
|
|
166
|
+
},
|
|
167
|
+
install: {
|
|
168
|
+
[Platform.Linux]: async () => {
|
|
169
|
+
(0, child_process_1.execSync)('sudo apt-get install -y zip', { stdio: 'inherit' });
|
|
170
|
+
return true;
|
|
171
|
+
},
|
|
172
|
+
},
|
|
173
|
+
instructions: {
|
|
174
|
+
[Platform.Win32]: 'zip is not required on Windows - PowerShell Compress-Archive will be used instead.',
|
|
175
|
+
},
|
|
176
|
+
},
|
|
177
|
+
];
|
|
178
|
+
/**
|
|
179
|
+
* Check all dependencies and return their status
|
|
180
|
+
*/
|
|
181
|
+
async function checkAllDependencies() {
|
|
182
|
+
const results = [];
|
|
183
|
+
for (const dep of exports.DEPENDENCIES) {
|
|
184
|
+
const status = await dep.check();
|
|
185
|
+
results.push(status);
|
|
186
|
+
}
|
|
187
|
+
return results;
|
|
188
|
+
}
|
|
189
|
+
/**
|
|
190
|
+
* Display dependency status with checkmarks/X
|
|
191
|
+
*/
|
|
192
|
+
function displayStatus(statuses) {
|
|
193
|
+
console.log(chalk_1.default.blue('\nChecking dependencies...\n'));
|
|
194
|
+
for (const status of statuses) {
|
|
195
|
+
if (status.installed) {
|
|
196
|
+
const version = status.version ? ` ${status.version}` : '';
|
|
197
|
+
console.log(chalk_1.default.green(`✓ ${status.name}${version}`));
|
|
198
|
+
}
|
|
199
|
+
else {
|
|
200
|
+
console.log(chalk_1.default.red(`✗ ${status.name} not found`));
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
console.log('');
|
|
204
|
+
}
|
|
205
|
+
/**
|
|
206
|
+
* Main entry point - check dependencies and prompt to install if needed
|
|
207
|
+
*/
|
|
208
|
+
async function ensureDependencies() {
|
|
209
|
+
const statuses = await checkAllDependencies();
|
|
210
|
+
displayStatus(statuses);
|
|
211
|
+
const missing = statuses.filter((s) => !s.installed);
|
|
212
|
+
if (missing.length === 0)
|
|
213
|
+
return;
|
|
214
|
+
const currentPlatform = getPlatform();
|
|
215
|
+
const installable = missing.filter((s) => {
|
|
216
|
+
const dep = exports.DEPENDENCIES.find((d) => d.name === s.name);
|
|
217
|
+
return dep?.install?.[currentPlatform];
|
|
218
|
+
});
|
|
219
|
+
// Prompt to install if we can auto-install some
|
|
220
|
+
if (installable.length > 0) {
|
|
221
|
+
const names = installable.map((d) => d.name).join(', ');
|
|
222
|
+
const { proceed } = await inquirer_1.default.prompt([
|
|
223
|
+
{
|
|
224
|
+
type: 'confirm',
|
|
225
|
+
name: 'proceed',
|
|
226
|
+
message: `Install missing dependencies (${names})?`,
|
|
227
|
+
default: true,
|
|
228
|
+
},
|
|
229
|
+
]);
|
|
230
|
+
if (proceed) {
|
|
231
|
+
for (const status of installable) {
|
|
232
|
+
const dep = exports.DEPENDENCIES.find((d) => d.name === status.name);
|
|
233
|
+
if (!dep || !dep.install || !dep.install[currentPlatform]) {
|
|
234
|
+
continue;
|
|
235
|
+
}
|
|
236
|
+
const installFn = dep.install[currentPlatform];
|
|
237
|
+
console.log(chalk_1.default.blue(`\nInstalling ${status.name}...`));
|
|
238
|
+
try {
|
|
239
|
+
await installFn();
|
|
240
|
+
console.log(chalk_1.default.green(`✓ ${status.name} installed`));
|
|
241
|
+
}
|
|
242
|
+
catch (error) {
|
|
243
|
+
console.log(chalk_1.default.red(`✗ Failed to install ${status.name}`));
|
|
244
|
+
}
|
|
245
|
+
}
|
|
246
|
+
}
|
|
247
|
+
}
|
|
248
|
+
// Re-check and show instructions for any still missing
|
|
249
|
+
const recheck = await checkAllDependencies();
|
|
250
|
+
const stillMissing = recheck.filter((s) => !s.installed);
|
|
251
|
+
if (stillMissing.length > 0) {
|
|
252
|
+
console.log(chalk_1.default.yellow('\nTo continue, install manually:\n'));
|
|
253
|
+
for (const status of stillMissing) {
|
|
254
|
+
const dep = exports.DEPENDENCIES.find((d) => d.name === status.name);
|
|
255
|
+
const instruction = dep?.instructions?.[currentPlatform];
|
|
256
|
+
if (instruction) {
|
|
257
|
+
console.log(chalk_1.default.white(` ${status.name}: ${instruction}`));
|
|
258
|
+
}
|
|
259
|
+
else {
|
|
260
|
+
console.log(chalk_1.default.white(` ${status.name}: See documentation for installation`));
|
|
261
|
+
}
|
|
262
|
+
}
|
|
263
|
+
console.log('');
|
|
264
|
+
process.exit(1);
|
|
265
|
+
}
|
|
266
|
+
}
|
|
267
|
+
//# sourceMappingURL=dependencies.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dependencies.js","sourceRoot":"","sources":["../../src/utils/dependencies.ts"],"names":[],"mappings":";AAAA,qEAAqE;AACrE,kEAAkE;;;;;;AA0BlE,kCAKC;AAiKD,oDAOC;AAqBD,gDA6DC;AAvRD,iDAAyC;AACzC,2BAA8B;AAC9B,kDAA0B;AAC1B,wDAAgC;AAEhC,IAAY,QAIX;AAJD,WAAY,QAAQ;IAClB,6BAAiB,CAAA;IACjB,2BAAe,CAAA;IACf,2BAAe,CAAA;AACjB,CAAC,EAJW,QAAQ,wBAAR,QAAQ,QAInB;AAeD,SAAgB,WAAW;IACzB,MAAM,CAAC,GAAG,IAAA,aAAQ,GAAE,CAAC;IACrB,IAAI,CAAC,KAAK,QAAQ;QAAE,OAAO,QAAQ,CAAC,MAAM,CAAC;IAC3C,IAAI,CAAC,KAAK,OAAO;QAAE,OAAO,QAAQ,CAAC,KAAK,CAAC;IACzC,OAAO,QAAQ,CAAC,KAAK,CAAC;AACxB,CAAC;AAEY,QAAA,YAAY,GAAiB;IACxC;QACE,IAAI,EAAE,MAAM;QACZ,KAAK,EAAE,KAAK,IAAI,EAAE;YAChB,IAAI,CAAC;gBACH,MAAM,OAAO,GAAG,IAAA,wBAAQ,EAAC,gBAAgB,CAAC,CAAC,QAAQ,EAAE,CAAC,IAAI,EAAE,CAAC;gBAC7D,MAAM,KAAK,GAAG,QAAQ,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;gBAC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AC;YAC7D,MAAM,WAAW,GAAG,GAAG,EAAE,YAAY,EAAE,CAAC,eAAe,CAAC,CAAC;YACzD,IAAI,WAAW,EAAE,CAAC;gBAChB,OAAO,CAAC,GAAG,CAAC,eAAK,CAAC,KAAK,CAAC,KAAK,MAAM,CAAC,IAAI,KAAK,WAAW,EAAE,CAAC,CAAC,CAAC;YAC/D,CAAC;iBAAM,CAAC;gBACN,OAAO,CAAC,GAAG,CAAC,eAAK,CAAC,KAAK,CAAC,KAAK,MAAM,CAAC,IAAI,sCAAsC,CAAC,CAAC,CAAC;YACnF,CAAC;QACH,CAAC;QACD,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;QAChB,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAClB,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export interface TemplateVariables {
|
|
2
|
+
appName: string;
|
|
3
|
+
applicationType: string;
|
|
4
|
+
lambdaName: string;
|
|
5
|
+
constructsPath: string;
|
|
6
|
+
department: string;
|
|
7
|
+
team: string;
|
|
8
|
+
contact: string;
|
|
9
|
+
compliance: string;
|
|
10
|
+
complianceJson: string;
|
|
11
|
+
confidentiality: string;
|
|
12
|
+
devProfile: string;
|
|
13
|
+
devVpc: string;
|
|
14
|
+
testProfile: string;
|
|
15
|
+
testVpc: string;
|
|
16
|
+
prodProfile: string;
|
|
17
|
+
prodVpc: string;
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* Copy a template file or directory to a destination, applying variable substitutions
|
|
21
|
+
*/
|
|
22
|
+
export declare function copyTemplate(templatePath: string, destPath: string, variables: TemplateVariables): Promise<void>;
|
|
23
|
+
//# sourceMappingURL=template.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"template.d.ts","sourceRoot":"","sources":["../../src/utils/template.ts"],"names":[],"mappings":"AAMA,MAAM,WAAW,iBAAiB;IAChC,OAAO,EAAE,MAAM,CAAC;IAChB,eAAe,EAAE,MAAM,CAAC;IACxB,UAAU,EAAE,MAAM,CAAC;IACnB,cAAc,EAAE,MAAM,CAAC;IACvB,UAAU,EAAE,MAAM,CAAC;IACnB,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,UAAU,EAAE,MAAM,CAAC;IACnB,cAAc,EAAE,MAAM,CAAC;IACvB,eAAe,EAAE,MAAM,CAAC;IACxB,UAAU,EAAE,MAAM,CAAC;IACnB,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,EAAE,MAAM,CAAC;IACpB,OAAO,EAAE,MAAM,CAAC;IAChB,WAAW,EAAE,MAAM,CAAC;IACpB,OAAO,EAAE,MAAM,CAAC;CACjB;AAED;;GAEG;AACH,wBAAsB,YAAY,CAChC,YAAY,EAAE,MAAM,EACpB,QAAQ,EAAE,MAAM,EAChB,SAAS,EAAE,iBAAiB,GAC3B,OAAO,CAAC,IAAI,CAAC,CAaf"}
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// ABOUTME: Template file copying with variable substitution
|
|
3
|
+
// ABOUTME: Handles {{variable}} replacement and __dirname__ renaming
|
|
4
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
5
|
+
if (k2 === undefined) k2 = k;
|
|
6
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
7
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
8
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
9
|
+
}
|
|
10
|
+
Object.defineProperty(o, k2, desc);
|
|
11
|
+
}) : (function(o, m, k, k2) {
|
|
12
|
+
if (k2 === undefined) k2 = k;
|
|
13
|
+
o[k2] = m[k];
|
|
14
|
+
}));
|
|
15
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
16
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
17
|
+
}) : function(o, v) {
|
|
18
|
+
o["default"] = v;
|
|
19
|
+
});
|
|
20
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
21
|
+
var ownKeys = function(o) {
|
|
22
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
23
|
+
var ar = [];
|
|
24
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
25
|
+
return ar;
|
|
26
|
+
};
|
|
27
|
+
return ownKeys(o);
|
|
28
|
+
};
|
|
29
|
+
return function (mod) {
|
|
30
|
+
if (mod && mod.__esModule) return mod;
|
|
31
|
+
var result = {};
|
|
32
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
33
|
+
__setModuleDefault(result, mod);
|
|
34
|
+
return result;
|
|
35
|
+
};
|
|
36
|
+
})();
|
|
37
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
38
|
+
exports.copyTemplate = copyTemplate;
|
|
39
|
+
const fs = __importStar(require("fs-extra"));
|
|
40
|
+
const path = __importStar(require("path"));
|
|
41
|
+
/**
|
|
42
|
+
* Copy a template file or directory to a destination, applying variable substitutions
|
|
43
|
+
*/
|
|
44
|
+
async function copyTemplate(templatePath, destPath, variables) {
|
|
45
|
+
const stats = await fs.stat(templatePath);
|
|
46
|
+
if (stats.isDirectory()) {
|
|
47
|
+
await processDirectory(templatePath, destPath, variables);
|
|
48
|
+
}
|
|
49
|
+
else {
|
|
50
|
+
// Single file - process and write to destination
|
|
51
|
+
let destFileName = path.basename(templatePath);
|
|
52
|
+
if (destFileName.endsWith('.tmpl')) {
|
|
53
|
+
destFileName = destFileName.slice(0, -5);
|
|
54
|
+
}
|
|
55
|
+
await fs.ensureDir(destPath);
|
|
56
|
+
await processFile(templatePath, path.join(destPath, destFileName), variables);
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
async function processDirectory(srcDir, destDir, variables) {
|
|
60
|
+
await fs.ensureDir(destDir);
|
|
61
|
+
const entries = await fs.readdir(srcDir, { withFileTypes: true });
|
|
62
|
+
for (const entry of entries) {
|
|
63
|
+
const srcPath = path.join(srcDir, entry.name);
|
|
64
|
+
let destName = applyVariablesToPath(entry.name, variables);
|
|
65
|
+
// Strip .tmpl extension
|
|
66
|
+
if (destName.endsWith('.tmpl')) {
|
|
67
|
+
destName = destName.slice(0, -5);
|
|
68
|
+
}
|
|
69
|
+
const destPath = path.join(destDir, destName);
|
|
70
|
+
if (entry.isDirectory()) {
|
|
71
|
+
await processDirectory(srcPath, destPath, variables);
|
|
72
|
+
}
|
|
73
|
+
else {
|
|
74
|
+
await processFile(srcPath, destPath, variables);
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
async function processFile(srcPath, destPath, variables) {
|
|
79
|
+
const content = await fs.readFile(srcPath, 'utf-8');
|
|
80
|
+
const processed = applyVariables(content, variables);
|
|
81
|
+
await fs.writeFile(destPath, processed);
|
|
82
|
+
}
|
|
83
|
+
/**
|
|
84
|
+
* Replace {{variable}} patterns in content
|
|
85
|
+
*/
|
|
86
|
+
function applyVariables(content, variables) {
|
|
87
|
+
return content
|
|
88
|
+
.replace(/\{\{appName\}\}/g, variables.appName)
|
|
89
|
+
.replace(/\{\{applicationType\}\}/g, variables.applicationType)
|
|
90
|
+
.replace(/\{\{lambdaName\}\}/g, variables.lambdaName)
|
|
91
|
+
.replace(/\{\{constructsPath\}\}/g, variables.constructsPath)
|
|
92
|
+
.replace(/\{\{department\}\}/g, variables.department)
|
|
93
|
+
.replace(/\{\{team\}\}/g, variables.team)
|
|
94
|
+
.replace(/\{\{contact\}\}/g, variables.contact)
|
|
95
|
+
.replace(/\{\{compliance\}\}/g, variables.compliance)
|
|
96
|
+
.replace(/\{\{complianceJson\}\}/g, variables.complianceJson)
|
|
97
|
+
.replace(/\{\{confidentiality\}\}/g, variables.confidentiality)
|
|
98
|
+
.replace(/\{\{COMPLIANCE\}\}/g, variables.compliance.toUpperCase())
|
|
99
|
+
.replace(/\{\{CONFIDENTIALITY\}\}/g, variables.confidentiality.toUpperCase())
|
|
100
|
+
.replace(/\{\{devProfile\}\}/g, variables.devProfile)
|
|
101
|
+
.replace(/\{\{devVpc\}\}/g, variables.devVpc)
|
|
102
|
+
.replace(/\{\{testProfile\}\}/g, variables.testProfile)
|
|
103
|
+
.replace(/\{\{testVpc\}\}/g, variables.testVpc)
|
|
104
|
+
.replace(/\{\{prodProfile\}\}/g, variables.prodProfile)
|
|
105
|
+
.replace(/\{\{prodVpc\}\}/g, variables.prodVpc);
|
|
106
|
+
}
|
|
107
|
+
/**
|
|
108
|
+
* Replace __variable__ patterns in paths (for directory names)
|
|
109
|
+
*/
|
|
110
|
+
function applyVariablesToPath(name, variables) {
|
|
111
|
+
return name
|
|
112
|
+
.replace(/__appName__/g, variables.appName)
|
|
113
|
+
.replace(/__lambdaName__/g, variables.lambdaName);
|
|
114
|
+
}
|
|
115
|
+
//# sourceMappingURL=template.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"template.js","sourceRoot":"","sources":["../../src/utils/template.ts"],"names":[],"mappings":";AAAA,4DAA4D;AAC5D,qEAAqE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA2BrE,oCAiBC;AA1CD,6CAA+B;AAC/B,2CAA6B;AAqB7B;;GAEG;AACI,KAAK,UAAU,YAAY,CAChC,YAAoB,EACpB,QAAgB,EAChB,SAA4B;IAE5B,MAAM,KAAK,GAAG,MAAM,EAAE,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC;IAC1C,IAAI,KAAK,CAAC,WAAW,EAAE,EAAE,CAAC;QACxB,MAAM,gBAAgB,CAAC,YAAY,EAAE,QAAQ,EAAE,SAAS,CAAC,CAAC;IAC5D,CAAC;SAAM,CAAC;QACN,iDAAiD;QACjD,IAAI,YAAY,GAAG,IAAI,CAAC,QAAQ,CAAC,YAAY,CAAC,CAAC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S,CAAC,MAAM,CAAC;SAC5C,OAAO,CAAC,sBAAsB,EAAE,SAAS,CAAC,WAAW,CAAC;SACtD,OAAO,CAAC,kBAAkB,EAAE,SAAS,CAAC,OAAO,CAAC;SAC9C,OAAO,CAAC,sBAAsB,EAAE,SAAS,CAAC,WAAW,CAAC;SACtD,OAAO,CAAC,kBAAkB,EAAE,SAAS,CAAC,OAAO,CAAC,CAAC;AACpD,CAAC;AAED;;GAEG;AACH,SAAS,oBAAoB,CAAC,IAAY,EAAE,SAA4B;IACtE,OAAO,IAAI;SACR,OAAO,CAAC,cAAc,EAAE,SAAS,CAAC,OAAO,CAAC;SAC1C,OAAO,CAAC,iBAAiB,EAAE,SAAS,CAAC,UAAU,CAAC,CAAC;AACtD,CAAC"}
|
package/package.json
ADDED
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@phila/cli",
|
|
3
|
+
"version": "0.0.1",
|
|
4
|
+
"description": "CLI tool for City of Philadelphia AWS infrastructure",
|
|
5
|
+
"main": "dist/index.js",
|
|
6
|
+
"bin": {
|
|
7
|
+
"city": "./dist/index.js"
|
|
8
|
+
},
|
|
9
|
+
"repository": {
|
|
10
|
+
"type": "git",
|
|
11
|
+
"url": "https://github.com/CityOfPhiladelphia/phila-ctl.git",
|
|
12
|
+
"directory": "packages/cli"
|
|
13
|
+
},
|
|
14
|
+
"publishConfig": {
|
|
15
|
+
"access": "public"
|
|
16
|
+
},
|
|
17
|
+
"files": [
|
|
18
|
+
"dist"
|
|
19
|
+
],
|
|
20
|
+
"dependencies": {
|
|
21
|
+
"aws-cdk": "^2.100.0",
|
|
22
|
+
"aws-sdk": "^2.1400.0",
|
|
23
|
+
"chalk": "^4.1.2",
|
|
24
|
+
"commander": "^11.0.0",
|
|
25
|
+
"fs-extra": "^11.1.0",
|
|
26
|
+
"inquirer": "^8.2.5",
|
|
27
|
+
"@phila/constructs": "0.0.1"
|
|
28
|
+
},
|
|
29
|
+
"devDependencies": {
|
|
30
|
+
"@types/fs-extra": "^11.0.0",
|
|
31
|
+
"@types/inquirer": "^9.0.0",
|
|
32
|
+
"@types/jest": "^29.5.0",
|
|
33
|
+
"@types/node": "^20.0.0",
|
|
34
|
+
"@typescript-eslint/eslint-plugin": "^6.0.0",
|
|
35
|
+
"@typescript-eslint/parser": "^6.0.0",
|
|
36
|
+
"eslint": "^8.50.0",
|
|
37
|
+
"jest": "^29.7.0",
|
|
38
|
+
"ts-jest": "^29.1.0",
|
|
39
|
+
"typescript": "^5.2.0"
|
|
40
|
+
},
|
|
41
|
+
"scripts": {
|
|
42
|
+
"build": "tsc && npm run copy-templates",
|
|
43
|
+
"copy-templates": "node scripts/copy-templates.js",
|
|
44
|
+
"test": "jest",
|
|
45
|
+
"lint": "eslint \"src/**/*.ts\"",
|
|
46
|
+
"clean": "rm -rf dist"
|
|
47
|
+
}
|
|
48
|
+
}
|