workspai 0.43.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/LICENSE +21 -0
- package/README.md +624 -0
- package/contracts/agent-customization-pack.v1.json +229 -0
- package/contracts/analyze-last-run.v1.json +106 -0
- package/contracts/artifact-remediation-plan.v1.json +163 -0
- package/contracts/backend-import-stack-parity.snapshot.json +37 -0
- package/contracts/cli-log-event.v1.json +51 -0
- package/contracts/create-planner-capabilities.v1.json +251 -0
- package/contracts/doctor-project-evidence.v1.json +304 -0
- package/contracts/doctor-remediation-plan.v1.json +496 -0
- package/contracts/doctor-workspace-evidence.v1.json +315 -0
- package/contracts/extension-cli-compatibility.v1.json +26 -0
- package/contracts/infra-stack.v1.json +305 -0
- package/contracts/module-layout.v1.json +34 -0
- package/contracts/module-support.v1.json +20 -0
- package/contracts/pipeline-last-run.v1.json +80 -0
- package/contracts/release-readiness.v1.json +60 -0
- package/contracts/runtime-command-surface.v1.json +364 -0
- package/contracts/workspace-intelligence/agent-action-outcome.v1.json +38 -0
- package/contracts/workspace-intelligence/blocker-resolution.v1.json +65 -0
- package/contracts/workspace-intelligence/doctor-fix-result.v1.json +44 -0
- package/contracts/workspace-intelligence/fact-freshness.v1.json +58 -0
- package/contracts/workspace-intelligence/studio-blocker-handoff.v1.json +115 -0
- package/contracts/workspace-intelligence/workspace-context.v1.json +142 -0
- package/contracts/workspace-intelligence/workspace-contract-verify.v1.json +51 -0
- package/contracts/workspace-intelligence/workspace-dependency-graph.v1.json +152 -0
- package/contracts/workspace-intelligence/workspace-explain.v1.json +31 -0
- package/contracts/workspace-intelligence/workspace-impact.v1.json +114 -0
- package/contracts/workspace-intelligence/workspace-intelligence-history.v1.json +40 -0
- package/contracts/workspace-intelligence/workspace-model-diff.v1.json +105 -0
- package/contracts/workspace-intelligence/workspace-model-snapshot.v1.json +36 -0
- package/contracts/workspace-intelligence/workspace-model.v1.json +135 -0
- package/contracts/workspace-intelligence/workspace-operational-skill.v1.json +37 -0
- package/contracts/workspace-intelligence/workspace-skills-index.v1.json +27 -0
- package/contracts/workspace-intelligence/workspace-verify.v1.json +213 -0
- package/contracts/workspace-registry.v1.json +83 -0
- package/contracts/workspace-run-last.v1.json +112 -0
- package/data/modules-embeddings.json +16953 -0
- package/dist/analyze-5BU4QIPK.js +1 -0
- package/dist/artifact-remediation-plan-5GJWPPRS.js +3 -0
- package/dist/autopilot-release-QYUOVB26.js +1 -0
- package/dist/chunk-22DT744Z.js +1 -0
- package/dist/chunk-2E6WGUN6.js +1 -0
- package/dist/chunk-2FIX2MDC.js +1 -0
- package/dist/chunk-3KXW53QI.js +1 -0
- package/dist/chunk-3ZK2GU7C.js +1 -0
- package/dist/chunk-4KUIFXHM.js +5 -0
- package/dist/chunk-54XJNLYC.js +13 -0
- package/dist/chunk-5SWNSJGW.js +1 -0
- package/dist/chunk-5XATWNME.js +1 -0
- package/dist/chunk-753LOKFZ.js +2 -0
- package/dist/chunk-7YHK5NM3.js +2 -0
- package/dist/chunk-A5FBGRJA.js +1 -0
- package/dist/chunk-AAKUNWPR.js +78 -0
- package/dist/chunk-AFSZHLQT.js +1 -0
- package/dist/chunk-AQ4XZZC6.js +1 -0
- package/dist/chunk-CVTCPPEF.js +1 -0
- package/dist/chunk-DNAY5ALC.js +1 -0
- package/dist/chunk-EWYYLJQY.js +2 -0
- package/dist/chunk-GSWPGELT.js +2 -0
- package/dist/chunk-GZTYAEWX.js +1 -0
- package/dist/chunk-HTYMXMQM.js +1 -0
- package/dist/chunk-IBJEQHJR.js +205 -0
- package/dist/chunk-ICGWHIMK.js +1 -0
- package/dist/chunk-JEI6BTZI.js +3 -0
- package/dist/chunk-JHC6SCJC.js +1 -0
- package/dist/chunk-LO4C4VXR.js +4 -0
- package/dist/chunk-LPZFK3Y6.js +920 -0
- package/dist/chunk-LUP4U6EE.js +1 -0
- package/dist/chunk-LYC6AIF2.js +2 -0
- package/dist/chunk-LZQNVH7D.js +1 -0
- package/dist/chunk-NAAQMSO3.js +1 -0
- package/dist/chunk-NFUXULIF.js +1 -0
- package/dist/chunk-OCGZNSOE.js +1 -0
- package/dist/chunk-OJEWQO3Z.js +33 -0
- package/dist/chunk-OL64GWQC.js +9 -0
- package/dist/chunk-PI5KUXDA.js +7 -0
- package/dist/chunk-PYCJWW4B.js +1 -0
- package/dist/chunk-RE773WOX.js +13 -0
- package/dist/chunk-RO73VVHW.js +2 -0
- package/dist/chunk-S5KTATOU.js +1 -0
- package/dist/chunk-SI3AQKIP.js +1 -0
- package/dist/chunk-T3GJ7YVG.js +1 -0
- package/dist/chunk-T6OR6YOI.js +2 -0
- package/dist/chunk-VRDF2J46.js +653 -0
- package/dist/chunk-VZKSNUEE.js +2 -0
- package/dist/chunk-WU4ZRRA5.js +4 -0
- package/dist/chunk-XEJD4KCV.js +33 -0
- package/dist/chunk-XZGVNGRB.js +1 -0
- package/dist/chunk-Y45WZR5N.js +5 -0
- package/dist/create-WRZO4HK2.js +1 -0
- package/dist/demo-kit-AJ5LIM5G.js +149 -0
- package/dist/doctor-MF3M3FS3.js +1 -0
- package/dist/dotnet-webapi-clean-IPY3MCGQ.js +425 -0
- package/dist/gofiber-standard-N5N3QGH3.js +1397 -0
- package/dist/gogin-standard-LAWQTBWL.js +1459 -0
- package/dist/imported-projects-registry-FOIE27WT.js +1 -0
- package/dist/index.d.ts +141 -0
- package/dist/index.js +454 -0
- package/dist/managed-agent-markers-AXUM75OE.js +8 -0
- package/dist/module-layout-NZ43RSC5.js +1 -0
- package/dist/pipeline-QCUHFWDY.js +5 -0
- package/dist/platform-capabilities-XAVU4HSM.js +1 -0
- package/dist/pythonRapidkitExec-3L3XJBSY.js +1 -0
- package/dist/springboot-standard-OZYF7ZM7.js +697 -0
- package/dist/workspace-PR6VZRBG.js +1 -0
- package/dist/workspace-agent-sync-KTYF3HQR.js +1 -0
- package/dist/workspace-archive-GCZNI44O.js +3 -0
- package/dist/workspace-context-QUTOP2XV.js +1 -0
- package/dist/workspace-contract-XUGMCUSQ.js +1 -0
- package/dist/workspace-explain-JEONEGZZ.js +1 -0
- package/dist/workspace-explain-contract-DNS2YEL7.js +1 -0
- package/dist/workspace-feedback-R6H4UFZB.js +1 -0
- package/dist/workspace-foundation-KGSV4E6D.js +1 -0
- package/dist/workspace-graph-2A5THUCI.js +1 -0
- package/dist/workspace-history-CGCK2DJI.js +1 -0
- package/dist/workspace-intelligence-QJGVL37U.js +1 -0
- package/dist/workspace-marker-SMBC3Z2Q.js +1 -0
- package/dist/workspace-mcp-serve-AK4MYEHQ.js +3 -0
- package/dist/workspace-model-PNXXOGPO.js +1 -0
- package/dist/workspace-python-engine-state-MTWIIZPY.js +2 -0
- package/dist/workspace-registry-summary-RUJE6RPH.js +1 -0
- package/dist/workspace-run-Y7YMUIHX.js +1 -0
- package/dist/workspace-verify-WSDUUTR5.js +1 -0
- package/dist/workspace-watch-AGPOJ74Q.js +1 -0
- package/docs/AI_DYNAMIC_INTEGRATION.md +440 -0
- package/docs/AI_EXAMPLES.md +419 -0
- package/docs/AI_FEATURES.md +460 -0
- package/docs/AI_QUICKSTART.md +245 -0
- package/docs/DEVELOPMENT.md +90 -0
- package/docs/From Code to Shared Understanding.png +0 -0
- package/docs/OPEN_SOURCE_USER_SCENARIOS.md +170 -0
- package/docs/OPTIMIZATION_GUIDE.md +504 -0
- package/docs/PACKAGE_MANAGER_POLICY.md +25 -0
- package/docs/README.md +125 -0
- package/docs/SECURITY.md +63 -0
- package/docs/SETUP.md +107 -0
- package/docs/UTILITIES.md +221 -0
- package/docs/WORKSPACE_MARKER_SPEC.md +276 -0
- package/docs/ci-workflows.md +59 -0
- package/docs/commands-reference.md +172 -0
- package/docs/config-file-guide.md +299 -0
- package/docs/contracts/ARTIFACT_CATALOG.md +333 -0
- package/docs/contracts/CLI_LOG_EVENT_STREAM.md +123 -0
- package/docs/contracts/COMMAND_OWNERSHIP_MATRIX.md +138 -0
- package/docs/contracts/NAMING_AND_COEXISTENCE.md +60 -0
- package/docs/contracts/README.md +86 -0
- package/docs/contracts/RUNTIME_ACCEPTANCE_MATRIX.md +98 -0
- package/docs/contracts/RUNTIME_SUPPORT_MATRIX.md +75 -0
- package/docs/contracts/rapidkit-cli-contracts.json +239 -0
- package/docs/create-planner-capabilities.md +81 -0
- package/docs/doctor-command.md +467 -0
- package/docs/examples/ci-agent-grounding.yml +65 -0
- package/docs/from-code-to-shared-understanding.md +45 -0
- package/docs/governance-policy.enterprise.example.json +40 -0
- package/docs/mirror-config.enterprise.example.json +60 -0
- package/docs/policies.workspace.example.yml +23 -0
- package/docs/workspace-operations.md +160 -0
- package/docs/workspace-run.md +104 -0
- package/package.json +179 -0
- package/rapidkit.config.example.cjs +62 -0
- package/scripts/check-agent-customization-drift.mjs +78 -0
- package/scripts/check-cli-resolution.cjs +72 -0
- package/scripts/enforce-package-manager.cjs +10 -0
- package/scripts/enterprise-package-smoke.mjs +463 -0
- package/scripts/prepack-enterprise.mjs +43 -0
- package/templates/generator.js +179 -0
- package/templates/kits/fastapi-ddd/README.md.j2 +117 -0
- package/templates/kits/fastapi-ddd/common/env.example.j2 +10 -0
- package/templates/kits/fastapi-ddd/env.example.j2 +1 -0
- package/templates/kits/fastapi-ddd/pyproject.toml.j2 +64 -0
- package/templates/kits/fastapi-ddd/src/__init__.py.j2 +3 -0
- package/templates/kits/fastapi-ddd/src/app/__init__.py.j2 +11 -0
- package/templates/kits/fastapi-ddd/src/app/application/__init__.py.j2 +5 -0
- package/templates/kits/fastapi-ddd/src/app/application/interfaces.py.j2 +43 -0
- package/templates/kits/fastapi-ddd/src/app/application/use_cases/__init__.py.j2 +6 -0
- package/templates/kits/fastapi-ddd/src/app/application/use_cases/health.py.j2 +14 -0
- package/templates/kits/fastapi-ddd/src/app/application/use_cases/notes.py.j2 +24 -0
- package/templates/kits/fastapi-ddd/src/app/config/__init__.py.j2 +16 -0
- package/templates/kits/fastapi-ddd/src/app/domain/__init__.py.j2 +3 -0
- package/templates/kits/fastapi-ddd/src/app/domain/models/__init__.py.j2 +6 -0
- package/templates/kits/fastapi-ddd/src/app/domain/models/health.py.j2 +16 -0
- package/templates/kits/fastapi-ddd/src/app/domain/models/note.py.j2 +27 -0
- package/templates/kits/fastapi-ddd/src/app/infrastructure/__init__.py.j2 +5 -0
- package/templates/kits/fastapi-ddd/src/app/infrastructure/repositories/__init__.py.j2 +6 -0
- package/templates/kits/fastapi-ddd/src/app/infrastructure/repositories/health.py.j2 +17 -0
- package/templates/kits/fastapi-ddd/src/app/infrastructure/repositories/notes.py.j2 +28 -0
- package/templates/kits/fastapi-ddd/src/app/main.py.j2 +61 -0
- package/templates/kits/fastapi-ddd/src/app/presentation/__init__.py.j2 +3 -0
- package/templates/kits/fastapi-ddd/src/app/presentation/api/__init__.py.j2 +5 -0
- package/templates/kits/fastapi-ddd/src/app/presentation/api/dependencies/__init__.py.j2 +19 -0
- package/templates/kits/fastapi-ddd/src/app/presentation/api/router.py.j2 +10 -0
- package/templates/kits/fastapi-ddd/src/app/presentation/api/routes/__init__.py.j2 +5 -0
- package/templates/kits/fastapi-ddd/src/app/presentation/api/routes/health.py.j2 +27 -0
- package/templates/kits/fastapi-ddd/src/app/presentation/api/routes/notes.py.j2 +50 -0
- package/templates/kits/fastapi-ddd/src/app/shared/__init__.py.j2 +5 -0
- package/templates/kits/fastapi-ddd/src/app/shared/result.py.j2 +28 -0
- package/templates/kits/fastapi-ddd/src/cli.py.j2 +170 -0
- package/templates/kits/fastapi-ddd/src/main.py.j2 +35 -0
- package/templates/kits/fastapi-ddd/src/modules/__init__.py.j2 +3 -0
- package/templates/kits/fastapi-ddd/src/routing/__init__.py.j2 +13 -0
- package/templates/kits/fastapi-ddd/src/routing/health.py.j2 +7 -0
- package/templates/kits/fastapi-ddd/src/routing/notes.py.j2 +7 -0
- package/templates/kits/fastapi-ddd/tests/__init__.py.j2 +1 -0
- package/templates/kits/fastapi-ddd/tests/test_app_factory.py.j2 +22 -0
- package/templates/kits/fastapi-ddd/tests/test_health.py.j2 +17 -0
- package/templates/kits/fastapi-ddd/tests/test_notes.py.j2 +27 -0
- package/templates/kits/fastapi-standard/README.md.j2 +140 -0
- package/templates/kits/fastapi-standard/common/env.example.j2 +10 -0
- package/templates/kits/fastapi-standard/env.example.j2 +1 -0
- package/templates/kits/fastapi-standard/pyproject.toml.j2 +64 -0
- package/templates/kits/fastapi-standard/src/__init__.py.j2 +3 -0
- package/templates/kits/fastapi-standard/src/cli.py.j2 +171 -0
- package/templates/kits/fastapi-standard/src/main.py.j2 +66 -0
- package/templates/kits/fastapi-standard/src/modules/__init__.py.j2 +3 -0
- package/templates/kits/fastapi-standard/src/routing/__init__.py.j2 +16 -0
- package/templates/kits/fastapi-standard/src/routing/examples.py.j2 +71 -0
- package/templates/kits/fastapi-standard/src/routing/health.py.j2 +22 -0
- package/templates/kits/fastapi-standard/tests/__init__.py.j2 +1 -0
- package/templates/kits/fastapi-standard/tests/test_examples.py.j2 +29 -0
- package/templates/kits/fastapi-standard/tests/test_health.py.j2 +17 -0
- package/templates/kits/nestjs-standard/Dockerfile.j2 +41 -0
- package/templates/kits/nestjs-standard/README.md.j2 +134 -0
- package/templates/kits/nestjs-standard/docker-compose.yml.j2 +94 -0
- package/templates/kits/nestjs-standard/docs/README.md.j2 +15 -0
- package/templates/kits/nestjs-standard/env.example.j2 +18 -0
- package/templates/kits/nestjs-standard/eslint.config.cjs.j2 +9 -0
- package/templates/kits/nestjs-standard/jest.config.ts.j2 +28 -0
- package/templates/kits/nestjs-standard/nest-cli.json.j2 +10 -0
- package/templates/kits/nestjs-standard/package.json.j2 +101 -0
- package/templates/kits/nestjs-standard/src/app.controller.ts.j2 +14 -0
- package/templates/kits/nestjs-standard/src/app.module.ts.j2 +26 -0
- package/templates/kits/nestjs-standard/src/app.service.ts.j2 +16 -0
- package/templates/kits/nestjs-standard/src/auth/auth.controller.ts.j2 +20 -0
- package/templates/kits/nestjs-standard/src/auth/auth.module.ts.j2 +13 -0
- package/templates/kits/nestjs-standard/src/auth/auth.service.ts.j2 +6 -0
- package/templates/kits/nestjs-standard/src/auth/entities/token.entity.ts.j2 +3 -0
- package/templates/kits/nestjs-standard/src/auth/entities/user.entity.ts.j2 +3 -0
- package/templates/kits/nestjs-standard/src/auth/entities/webauthn.entity.ts.j2 +3 -0
- package/templates/kits/nestjs-standard/src/config/configuration.ts.j2 +85 -0
- package/templates/kits/nestjs-standard/src/config/index.ts.j2 +2 -0
- package/templates/kits/nestjs-standard/src/config/validation.ts.j2 +21 -0
- package/templates/kits/nestjs-standard/src/examples/dto/create-note.dto.ts.j2 +11 -0
- package/templates/kits/nestjs-standard/src/examples/examples.controller.ts.j2 +24 -0
- package/templates/kits/nestjs-standard/src/examples/examples.module.ts.j2 +10 -0
- package/templates/kits/nestjs-standard/src/examples/examples.service.ts.j2 +33 -0
- package/templates/kits/nestjs-standard/src/main.ts.j2 +53 -0
- package/templates/kits/nestjs-standard/src/modules/index.ts.j2 +25 -0
- package/templates/kits/nestjs-standard/test/app.controller.spec.ts.j2 +24 -0
- package/templates/kits/nestjs-standard/test/app.e2e-spec.ts.j2 +60 -0
- package/templates/kits/nestjs-standard/test/examples.controller.spec.ts.j2 +28 -0
- package/templates/kits/nestjs-standard/test/jest-e2e.json.j2 +15 -0
- package/templates/kits/nestjs-standard/tsconfig.build.json.j2 +12 -0
- package/templates/kits/nestjs-standard/tsconfig.json.j2 +26 -0
- package/workspai.config.example.cjs +62 -0
|
@@ -0,0 +1,425 @@
|
|
|
1
|
+
import {b,c}from'./chunk-IBJEQHJR.js';import {c as c$1}from'./chunk-Y45WZR5N.js';import {promises}from'fs';import n from'path';import i from'chalk';import b$1 from'ora';import {execa}from'execa';var C="net8.0",R="8080";function A(e){return e.trim().toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/^-+|-+$/g,"").replace(/-{2,}/g,"-")}function j(e,r){return e.trim().replace(/[^A-Za-z0-9_.]+/g,".").replace(/^\.+|\.+$/g,"").replace(/\.{2,}/g,".").split(".").map(a=>a.replace(/^[^A-Za-z_]+/,"").replace(/[^A-Za-z0-9_]/g,"")).filter(Boolean).join(".")||r}function S(e,r){return e.replace(/[\r\n\t]+/g," ").trim()||r}function y(e){return /^net\d+\.\d+$/.test(e.trim())}function _(){return JSON.stringify({engine:"npm",runtime:"dotnet"},null,2)}function E(e,r){return JSON.stringify({kit_name:"dotnet.webapi.clean",runtime:"dotnet",framework:"dotnet",module_support:false,project_name:e.project_name,root_namespace:e.root_namespace,target_framework:e.target_framework,app_version:e.app_version,created_by:"workspai",workspai_version:r,rapidkit_version:r,created_at:new Date().toISOString()},null,2)}function D(e){return `<Project Sdk="Microsoft.NET.Sdk.Web">
|
|
2
|
+
<PropertyGroup>
|
|
3
|
+
<TargetFramework>${e.target_framework}</TargetFramework>
|
|
4
|
+
<Nullable>enable</Nullable>
|
|
5
|
+
<ImplicitUsings>enable</ImplicitUsings>
|
|
6
|
+
<RootNamespace>${e.root_namespace}</RootNamespace>
|
|
7
|
+
<AssemblyName>${e.root_namespace}</AssemblyName>
|
|
8
|
+
<Version>${e.app_version}</Version>
|
|
9
|
+
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
|
|
10
|
+
<GenerateDocumentationFile>true</GenerateDocumentationFile>
|
|
11
|
+
<NoWarn>$(NoWarn);1591</NoWarn>
|
|
12
|
+
</PropertyGroup>
|
|
13
|
+
|
|
14
|
+
<ItemGroup>
|
|
15
|
+
<PackageReference Include="Microsoft.AspNetCore.OpenApi" Version="8.0.14" />
|
|
16
|
+
<PackageReference Include="Swashbuckle.AspNetCore" Version="6.6.2" />
|
|
17
|
+
</ItemGroup>
|
|
18
|
+
</Project>
|
|
19
|
+
`}function $(e){return `<Project Sdk="Microsoft.NET.Sdk">
|
|
20
|
+
<PropertyGroup>
|
|
21
|
+
<TargetFramework>${e.target_framework}</TargetFramework>
|
|
22
|
+
<ImplicitUsings>enable</ImplicitUsings>
|
|
23
|
+
<Nullable>enable</Nullable>
|
|
24
|
+
<IsPackable>false</IsPackable>
|
|
25
|
+
</PropertyGroup>
|
|
26
|
+
|
|
27
|
+
<ItemGroup>
|
|
28
|
+
<PackageReference Include="Microsoft.AspNetCore.Mvc.Testing" Version="8.0.14" />
|
|
29
|
+
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.11.1" />
|
|
30
|
+
<PackageReference Include="xunit" Version="2.9.2" />
|
|
31
|
+
<PackageReference Include="xunit.runner.visualstudio" Version="2.8.2" />
|
|
32
|
+
<PackageReference Include="coverlet.collector" Version="6.0.2" />
|
|
33
|
+
</ItemGroup>
|
|
34
|
+
|
|
35
|
+
<ItemGroup>
|
|
36
|
+
<ProjectReference Include="..\\src\\${e.project_name}.csproj" />
|
|
37
|
+
</ItemGroup>
|
|
38
|
+
</Project>
|
|
39
|
+
`}function I(e){return `using ${e.root_namespace}.Application;
|
|
40
|
+
using ${e.root_namespace}.Infrastructure;
|
|
41
|
+
using ${e.root_namespace}.Presentation;
|
|
42
|
+
|
|
43
|
+
var builder = WebApplication.CreateBuilder(args);
|
|
44
|
+
|
|
45
|
+
builder.Services.Configure<ApplicationInfoOptions>(
|
|
46
|
+
builder.Configuration.GetSection(ApplicationInfoOptions.SectionName));
|
|
47
|
+
builder.Services.AddApplicationServices();
|
|
48
|
+
builder.Services.AddInfrastructureServices();
|
|
49
|
+
builder.Services.AddPresentationServices();
|
|
50
|
+
builder.Services.AddHealthChecks();
|
|
51
|
+
builder.Services.AddEndpointsApiExplorer();
|
|
52
|
+
builder.Services.AddSwaggerGen();
|
|
53
|
+
|
|
54
|
+
var app = builder.Build();
|
|
55
|
+
|
|
56
|
+
if (app.Environment.IsDevelopment())
|
|
57
|
+
{
|
|
58
|
+
app.UseSwagger();
|
|
59
|
+
app.UseSwaggerUI(options => options.RoutePrefix = "docs");
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
app.UseExceptionHandler();
|
|
63
|
+
app.MapHealthChecks("/health/live");
|
|
64
|
+
app.MapHealthChecks("/health/ready");
|
|
65
|
+
app.MapSystemEndpoints();
|
|
66
|
+
|
|
67
|
+
app.Run();
|
|
68
|
+
|
|
69
|
+
public partial class Program
|
|
70
|
+
{
|
|
71
|
+
}
|
|
72
|
+
`}function P(e){return `namespace ${e.root_namespace}.Application;
|
|
73
|
+
|
|
74
|
+
public sealed class ApplicationInfoOptions
|
|
75
|
+
{
|
|
76
|
+
public const string SectionName = "Workspai";
|
|
77
|
+
|
|
78
|
+
public string Name { get; init; } = "${e.project_name}";
|
|
79
|
+
|
|
80
|
+
public string Version { get; init; } = "${e.app_version}";
|
|
81
|
+
|
|
82
|
+
public string Description { get; init; } = "${e.description}";
|
|
83
|
+
}
|
|
84
|
+
`}function k(e){return `using Microsoft.Extensions.DependencyInjection;
|
|
85
|
+
|
|
86
|
+
namespace ${e.root_namespace}.Application;
|
|
87
|
+
|
|
88
|
+
public static class ApplicationServiceRegistration
|
|
89
|
+
{
|
|
90
|
+
public static IServiceCollection AddApplicationServices(this IServiceCollection services)
|
|
91
|
+
{
|
|
92
|
+
services.AddSingleton<SystemInfoService>();
|
|
93
|
+
return services;
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
`}function T(e){return `using Microsoft.Extensions.Options;
|
|
97
|
+
|
|
98
|
+
namespace ${e.root_namespace}.Application;
|
|
99
|
+
|
|
100
|
+
public sealed record SystemInfoResponse(
|
|
101
|
+
string Name,
|
|
102
|
+
string Version,
|
|
103
|
+
string Runtime,
|
|
104
|
+
string Environment,
|
|
105
|
+
DateTimeOffset ServerTimeUtc);
|
|
106
|
+
|
|
107
|
+
public sealed class SystemInfoService(IOptions<ApplicationInfoOptions> options)
|
|
108
|
+
{
|
|
109
|
+
public SystemInfoResponse GetInfo(IHostEnvironment environment)
|
|
110
|
+
{
|
|
111
|
+
var info = options.Value;
|
|
112
|
+
return new SystemInfoResponse(
|
|
113
|
+
info.Name,
|
|
114
|
+
info.Version,
|
|
115
|
+
".NET",
|
|
116
|
+
environment.EnvironmentName,
|
|
117
|
+
DateTimeOffset.UtcNow);
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
`}function w(e){return `using Microsoft.Extensions.DependencyInjection;
|
|
121
|
+
|
|
122
|
+
namespace ${e.root_namespace}.Infrastructure;
|
|
123
|
+
|
|
124
|
+
public static class InfrastructureServiceRegistration
|
|
125
|
+
{
|
|
126
|
+
public static IServiceCollection AddInfrastructureServices(this IServiceCollection services)
|
|
127
|
+
{
|
|
128
|
+
return services;
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
`}function x(e){return `using Microsoft.AspNetCore.Diagnostics;
|
|
132
|
+
using Microsoft.AspNetCore.Http;
|
|
133
|
+
using Microsoft.Extensions.DependencyInjection;
|
|
134
|
+
|
|
135
|
+
namespace ${e.root_namespace}.Presentation;
|
|
136
|
+
|
|
137
|
+
public static class PresentationServiceRegistration
|
|
138
|
+
{
|
|
139
|
+
public static IServiceCollection AddPresentationServices(this IServiceCollection services)
|
|
140
|
+
{
|
|
141
|
+
services.AddExceptionHandler<GlobalExceptionHandler>();
|
|
142
|
+
services.AddProblemDetails();
|
|
143
|
+
return services;
|
|
144
|
+
}
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
internal sealed class GlobalExceptionHandler : IExceptionHandler
|
|
148
|
+
{
|
|
149
|
+
public async ValueTask<bool> TryHandleAsync(
|
|
150
|
+
HttpContext httpContext,
|
|
151
|
+
Exception exception,
|
|
152
|
+
CancellationToken cancellationToken)
|
|
153
|
+
{
|
|
154
|
+
httpContext.Response.StatusCode = StatusCodes.Status500InternalServerError;
|
|
155
|
+
await httpContext.Response.WriteAsJsonAsync(
|
|
156
|
+
new
|
|
157
|
+
{
|
|
158
|
+
error = "internal_error",
|
|
159
|
+
traceId = httpContext.TraceIdentifier,
|
|
160
|
+
},
|
|
161
|
+
cancellationToken);
|
|
162
|
+
return true;
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
`}function v(e){return `using ${e.root_namespace}.Application;
|
|
166
|
+
|
|
167
|
+
namespace ${e.root_namespace}.Presentation;
|
|
168
|
+
|
|
169
|
+
public static class SystemEndpoints
|
|
170
|
+
{
|
|
171
|
+
public static IEndpointRouteBuilder MapSystemEndpoints(this IEndpointRouteBuilder app)
|
|
172
|
+
{
|
|
173
|
+
var group = app.MapGroup("/api/v1/system").WithTags("System");
|
|
174
|
+
|
|
175
|
+
group.MapGet("/info", (SystemInfoService service, IHostEnvironment environment) =>
|
|
176
|
+
Results.Ok(service.GetInfo(environment)))
|
|
177
|
+
.WithName("GetSystemInfo")
|
|
178
|
+
.Produces<SystemInfoResponse>();
|
|
179
|
+
|
|
180
|
+
return app;
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
`}function d(e){return JSON.stringify({Workspai:{Name:e.project_name,Version:e.app_version,Description:e.description},Logging:{LogLevel:{Default:"Information","Microsoft.AspNetCore":"Warning"}},AllowedHosts:"*",Kestrel:{Endpoints:{Http:{Url:`http://0.0.0.0:${e.port}`}}}},null,2)}function N(e){return `FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build
|
|
184
|
+
WORKDIR /src
|
|
185
|
+
COPY src/*.csproj ./src/
|
|
186
|
+
COPY tests/*.csproj ./tests/
|
|
187
|
+
RUN dotnet restore ./src/${e.project_name}.csproj
|
|
188
|
+
COPY . .
|
|
189
|
+
RUN dotnet publish ./src/${e.project_name}.csproj -c Release -o /app/publish --no-restore
|
|
190
|
+
|
|
191
|
+
FROM mcr.microsoft.com/dotnet/aspnet:8.0
|
|
192
|
+
WORKDIR /app
|
|
193
|
+
RUN apt-get update \\
|
|
194
|
+
&& apt-get install -y --no-install-recommends curl \\
|
|
195
|
+
&& rm -rf /var/lib/apt/lists/*
|
|
196
|
+
ENV ASPNETCORE_URLS=http://+:${e.port}
|
|
197
|
+
COPY --from=build /app/publish .
|
|
198
|
+
HEALTHCHECK --interval=30s --timeout=5s --retries=3 CMD curl -fsS http://localhost:${e.port}/health/live || exit 1
|
|
199
|
+
ENTRYPOINT ["dotnet", "${e.root_namespace}.dll"]
|
|
200
|
+
`}function h(e){return `services:
|
|
201
|
+
api:
|
|
202
|
+
build: .
|
|
203
|
+
ports:
|
|
204
|
+
- "\${PORT:-${e.port}}:${e.port}"
|
|
205
|
+
environment:
|
|
206
|
+
ASPNETCORE_ENVIRONMENT: Development
|
|
207
|
+
ASPNETCORE_URLS: http://+:${e.port}
|
|
208
|
+
healthcheck:
|
|
209
|
+
test: ["CMD", "curl", "-fsS", "http://localhost:${e.port}/health/live"]
|
|
210
|
+
interval: 30s
|
|
211
|
+
timeout: 5s
|
|
212
|
+
retries: 3
|
|
213
|
+
`}function V(e){return `.PHONY: init dev start build test lint format docker-up docker-down
|
|
214
|
+
|
|
215
|
+
init:
|
|
216
|
+
dotnet restore src/${e.project_name}.csproj
|
|
217
|
+
dotnet tool restore || true
|
|
218
|
+
|
|
219
|
+
dev:
|
|
220
|
+
dotnet run --project src/${e.project_name}.csproj
|
|
221
|
+
|
|
222
|
+
start:
|
|
223
|
+
dotnet run --project src/${e.project_name}.csproj
|
|
224
|
+
|
|
225
|
+
build:
|
|
226
|
+
dotnet build src/${e.project_name}.csproj -c Release
|
|
227
|
+
|
|
228
|
+
test:
|
|
229
|
+
dotnet test tests/${e.project_name}.Tests.csproj --collect:"XPlat Code Coverage"
|
|
230
|
+
|
|
231
|
+
lint:
|
|
232
|
+
dotnet format src/${e.project_name}.csproj --verify-no-changes
|
|
233
|
+
dotnet format tests/${e.project_name}.Tests.csproj --verify-no-changes
|
|
234
|
+
|
|
235
|
+
format:
|
|
236
|
+
dotnet format src/${e.project_name}.csproj
|
|
237
|
+
dotnet format tests/${e.project_name}.Tests.csproj
|
|
238
|
+
|
|
239
|
+
docker-up:
|
|
240
|
+
docker compose up --build -d
|
|
241
|
+
|
|
242
|
+
docker-down:
|
|
243
|
+
docker compose down
|
|
244
|
+
`}function U(e){return `#!/usr/bin/env sh
|
|
245
|
+
SCRIPT_DIR=$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)
|
|
246
|
+
CMD="\${1:-help}"
|
|
247
|
+
shift 2>/dev/null || true
|
|
248
|
+
|
|
249
|
+
case "$CMD" in
|
|
250
|
+
init)
|
|
251
|
+
cd "$SCRIPT_DIR" || exit 1
|
|
252
|
+
dotnet restore "src/${e.project_name}.csproj" || exit $?
|
|
253
|
+
dotnet tool restore 2>/dev/null || true
|
|
254
|
+
;;
|
|
255
|
+
dev) exec dotnet run --project "$SCRIPT_DIR/src/${e.project_name}.csproj" "$@" ;;
|
|
256
|
+
start) exec dotnet run --project "$SCRIPT_DIR/src/${e.project_name}.csproj" "$@" ;;
|
|
257
|
+
build) exec dotnet build "$SCRIPT_DIR/src/${e.project_name}.csproj" -c Release "$@" ;;
|
|
258
|
+
test) exec dotnet test "$SCRIPT_DIR/tests/${e.project_name}.Tests.csproj" "$@" ;;
|
|
259
|
+
lint)
|
|
260
|
+
dotnet format "$SCRIPT_DIR/src/${e.project_name}.csproj" --verify-no-changes "$@" || exit $?
|
|
261
|
+
exec dotnet format "$SCRIPT_DIR/tests/${e.project_name}.Tests.csproj" --verify-no-changes "$@"
|
|
262
|
+
;;
|
|
263
|
+
format|fmt)
|
|
264
|
+
dotnet format "$SCRIPT_DIR/src/${e.project_name}.csproj" "$@" || exit $?
|
|
265
|
+
exec dotnet format "$SCRIPT_DIR/tests/${e.project_name}.Tests.csproj" "$@"
|
|
266
|
+
;;
|
|
267
|
+
help|--help|-h)
|
|
268
|
+
echo "Workspai \u2014 ASP.NET Core project: ${e.project_name}"
|
|
269
|
+
echo "Available: init, dev, start, build, test, lint, format"
|
|
270
|
+
;;
|
|
271
|
+
*) echo "rapidkit: unknown command: $CMD" >&2; exit 1 ;;
|
|
272
|
+
esac
|
|
273
|
+
`}function O(e){return `@echo off
|
|
274
|
+
set CMD=%1
|
|
275
|
+
if "%CMD%"=="" set CMD=help
|
|
276
|
+
shift
|
|
277
|
+
|
|
278
|
+
if "%CMD%"=="init" (
|
|
279
|
+
dotnet restore src\\${e.project_name}.csproj
|
|
280
|
+
if errorlevel 1 exit /b %ERRORLEVEL%
|
|
281
|
+
dotnet tool restore 2>nul
|
|
282
|
+
exit /b 0
|
|
283
|
+
)
|
|
284
|
+
if "%CMD%"=="dev" ( dotnet run --project src\\${e.project_name}.csproj %* & exit /b %ERRORLEVEL% )
|
|
285
|
+
if "%CMD%"=="start" ( dotnet run --project src\\${e.project_name}.csproj %* & exit /b %ERRORLEVEL% )
|
|
286
|
+
if "%CMD%"=="build" ( dotnet build src\\${e.project_name}.csproj -c Release %* & exit /b %ERRORLEVEL% )
|
|
287
|
+
if "%CMD%"=="test" ( dotnet test tests\\${e.project_name}.Tests.csproj %* & exit /b %ERRORLEVEL% )
|
|
288
|
+
if "%CMD%"=="lint" (
|
|
289
|
+
dotnet format src\\${e.project_name}.csproj --verify-no-changes %*
|
|
290
|
+
if errorlevel 1 exit /b %ERRORLEVEL%
|
|
291
|
+
dotnet format tests\\${e.project_name}.Tests.csproj --verify-no-changes %*
|
|
292
|
+
exit /b %ERRORLEVEL%
|
|
293
|
+
)
|
|
294
|
+
if "%CMD%"=="format" (
|
|
295
|
+
dotnet format src\\${e.project_name}.csproj %*
|
|
296
|
+
if errorlevel 1 exit /b %ERRORLEVEL%
|
|
297
|
+
dotnet format tests\\${e.project_name}.Tests.csproj %*
|
|
298
|
+
exit /b %ERRORLEVEL%
|
|
299
|
+
)
|
|
300
|
+
|
|
301
|
+
echo Available: init, dev, start, build, test, lint, format
|
|
302
|
+
exit /b 1
|
|
303
|
+
`}function W(e){return `name: CI
|
|
304
|
+
|
|
305
|
+
on:
|
|
306
|
+
push:
|
|
307
|
+
pull_request:
|
|
308
|
+
|
|
309
|
+
jobs:
|
|
310
|
+
verify:
|
|
311
|
+
runs-on: \${{ matrix.os }}
|
|
312
|
+
strategy:
|
|
313
|
+
fail-fast: false
|
|
314
|
+
matrix:
|
|
315
|
+
os: [ubuntu-latest, windows-latest]
|
|
316
|
+
steps:
|
|
317
|
+
- uses: actions/checkout@v4
|
|
318
|
+
- uses: actions/setup-dotnet@v4
|
|
319
|
+
with:
|
|
320
|
+
dotnet-version: 8.0.x
|
|
321
|
+
- name: Restore
|
|
322
|
+
run: |
|
|
323
|
+
dotnet restore src/${e.project_name}.csproj
|
|
324
|
+
dotnet restore tests/${e.project_name}.Tests.csproj
|
|
325
|
+
- name: Format check
|
|
326
|
+
run: |
|
|
327
|
+
dotnet format src/${e.project_name}.csproj --verify-no-changes
|
|
328
|
+
dotnet format tests/${e.project_name}.Tests.csproj --verify-no-changes
|
|
329
|
+
- name: Build
|
|
330
|
+
run: dotnet build src/${e.project_name}.csproj -c Release --no-restore
|
|
331
|
+
- name: Test
|
|
332
|
+
run: dotnet test tests/${e.project_name}.Tests.csproj -c Release --no-build --collect:"XPlat Code Coverage"
|
|
333
|
+
`}function M(e){return `using System.Net;
|
|
334
|
+
using Microsoft.AspNetCore.Mvc.Testing;
|
|
335
|
+
using Xunit;
|
|
336
|
+
|
|
337
|
+
namespace ${e.root_namespace}.Tests;
|
|
338
|
+
|
|
339
|
+
public sealed class RuntimeSmokeTests : IClassFixture<WebApplicationFactory<Program>>
|
|
340
|
+
{
|
|
341
|
+
private readonly WebApplicationFactory<Program> _factory;
|
|
342
|
+
|
|
343
|
+
public RuntimeSmokeTests(WebApplicationFactory<Program> factory)
|
|
344
|
+
{
|
|
345
|
+
_factory = factory;
|
|
346
|
+
}
|
|
347
|
+
|
|
348
|
+
[Fact]
|
|
349
|
+
public async Task HealthEndpointShouldReturnOk()
|
|
350
|
+
{
|
|
351
|
+
using var client = _factory.CreateClient();
|
|
352
|
+
var response = await client.GetAsync("/health/live");
|
|
353
|
+
Assert.Equal(HttpStatusCode.OK, response.StatusCode);
|
|
354
|
+
}
|
|
355
|
+
|
|
356
|
+
[Fact]
|
|
357
|
+
public async Task SystemInfoEndpointShouldReturnOk()
|
|
358
|
+
{
|
|
359
|
+
using var client = _factory.CreateClient();
|
|
360
|
+
var response = await client.GetAsync("/api/v1/system/info");
|
|
361
|
+
Assert.Equal(HttpStatusCode.OK, response.StatusCode);
|
|
362
|
+
}
|
|
363
|
+
}
|
|
364
|
+
`}function G(e){return `
|
|
365
|
+
Microsoft Visual Studio Solution File, Format Version 12.00
|
|
366
|
+
# Visual Studio Version 17
|
|
367
|
+
VisualStudioVersion = 17.0.31903.59
|
|
368
|
+
MinimumVisualStudioVersion = 10.0.40219.1
|
|
369
|
+
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{33333333-3333-3333-3333-333333333333}"
|
|
370
|
+
EndProject
|
|
371
|
+
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "tests", "tests", "{44444444-4444-4444-4444-444444444444}"
|
|
372
|
+
EndProject
|
|
373
|
+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "${e.project_name}", "src\\${e.project_name}.csproj", "{11111111-1111-1111-1111-111111111111}"
|
|
374
|
+
EndProject
|
|
375
|
+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "${e.project_name}.Tests", "tests\\${e.project_name}.Tests.csproj", "{22222222-2222-2222-2222-222222222222}"
|
|
376
|
+
EndProject
|
|
377
|
+
Global
|
|
378
|
+
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
|
379
|
+
Debug|Any CPU = Debug|Any CPU
|
|
380
|
+
Debug|x64 = Debug|x64
|
|
381
|
+
Debug|x86 = Debug|x86
|
|
382
|
+
Release|Any CPU = Release|Any CPU
|
|
383
|
+
Release|x64 = Release|x64
|
|
384
|
+
Release|x86 = Release|x86
|
|
385
|
+
EndGlobalSection
|
|
386
|
+
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
|
387
|
+
{11111111-1111-1111-1111-111111111111}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
|
388
|
+
{11111111-1111-1111-1111-111111111111}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
|
389
|
+
{11111111-1111-1111-1111-111111111111}.Debug|x64.ActiveCfg = Debug|Any CPU
|
|
390
|
+
{11111111-1111-1111-1111-111111111111}.Debug|x64.Build.0 = Debug|Any CPU
|
|
391
|
+
{11111111-1111-1111-1111-111111111111}.Debug|x86.ActiveCfg = Debug|Any CPU
|
|
392
|
+
{11111111-1111-1111-1111-111111111111}.Debug|x86.Build.0 = Debug|Any CPU
|
|
393
|
+
{11111111-1111-1111-1111-111111111111}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
|
394
|
+
{11111111-1111-1111-1111-111111111111}.Release|Any CPU.Build.0 = Release|Any CPU
|
|
395
|
+
{11111111-1111-1111-1111-111111111111}.Release|x64.ActiveCfg = Release|Any CPU
|
|
396
|
+
{11111111-1111-1111-1111-111111111111}.Release|x64.Build.0 = Release|Any CPU
|
|
397
|
+
{11111111-1111-1111-1111-111111111111}.Release|x86.ActiveCfg = Release|Any CPU
|
|
398
|
+
{11111111-1111-1111-1111-111111111111}.Release|x86.Build.0 = Release|Any CPU
|
|
399
|
+
{22222222-2222-2222-2222-222222222222}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
|
400
|
+
{22222222-2222-2222-2222-222222222222}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
|
401
|
+
{22222222-2222-2222-2222-222222222222}.Debug|x64.ActiveCfg = Debug|Any CPU
|
|
402
|
+
{22222222-2222-2222-2222-222222222222}.Debug|x64.Build.0 = Debug|Any CPU
|
|
403
|
+
{22222222-2222-2222-2222-222222222222}.Debug|x86.ActiveCfg = Debug|Any CPU
|
|
404
|
+
{22222222-2222-2222-2222-222222222222}.Debug|x86.Build.0 = Debug|Any CPU
|
|
405
|
+
{22222222-2222-2222-2222-222222222222}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
|
406
|
+
{22222222-2222-2222-2222-222222222222}.Release|Any CPU.Build.0 = Release|Any CPU
|
|
407
|
+
{22222222-2222-2222-2222-222222222222}.Release|x64.ActiveCfg = Release|Any CPU
|
|
408
|
+
{22222222-2222-2222-2222-222222222222}.Release|x64.Build.0 = Release|Any CPU
|
|
409
|
+
{22222222-2222-2222-2222-222222222222}.Release|x86.ActiveCfg = Release|Any CPU
|
|
410
|
+
{22222222-2222-2222-2222-222222222222}.Release|x86.Build.0 = Release|Any CPU
|
|
411
|
+
EndGlobalSection
|
|
412
|
+
GlobalSection(SolutionProperties) = preSolution
|
|
413
|
+
HideSolutionNode = FALSE
|
|
414
|
+
EndGlobalSection
|
|
415
|
+
GlobalSection(NestedProjects) = preSolution
|
|
416
|
+
{11111111-1111-1111-1111-111111111111} = {33333333-3333-3333-3333-333333333333}
|
|
417
|
+
{22222222-2222-2222-2222-222222222222} = {44444444-4444-4444-4444-444444444444}
|
|
418
|
+
EndGlobalSection
|
|
419
|
+
EndGlobal
|
|
420
|
+
`.trimStart()}async function F(e,r){if(!r)try{await execa("git",["init"],{cwd:e,stdio:"ignore"});}catch{console.log(i.gray("\u26A0 git init skipped (git not found or error)"));}}async function L(e){try{await execa("dotnet",["--version"],{cwd:e,timeout:3e3,stdio:"pipe"});}catch{console.log(i.yellow("\u26A0 .NET SDK not found in PATH - project scaffolded, but init/build need .NET 8+")),console.log(i.gray(" Install: https://dotnet.microsoft.com/download"));}}async function Q(e,r){let s=A(r.project_name)||"dotnet-api",c$2=j(r.root_namespace||`Workspai.${b(s)}`,"Workspai.App"),a=r.target_framework&&y(r.target_framework)?r.target_framework:C,g=r.port&&/^\d+$/.test(r.port)?r.port:R,o={project_name:s,root_namespace:c$2,description:S(r.description||"","Production-ready ASP.NET Core Web API scaffolded by Workspai."),target_framework:a,app_version:r.app_version||"0.1.0",port:g,skipGit:r.skipGit??false},f=b$1(`Creating ASP.NET Core Web API project ${s}`).start();await promises.mkdir(e,{recursive:true}),await c(n.join(e,`${s}.sln`),G(o)),await c(n.join(e,"src",`${s}.csproj`),D(o)),await c(n.join(e,"src","Program.cs"),I(o)),await c(n.join(e,"src","Application","ApplicationInfoOptions.cs"),P(o)),await c(n.join(e,"src","Application","ApplicationServiceRegistration.cs"),k(o)),await c(n.join(e,"src","Application","SystemInfoService.cs"),T(o)),await c(n.join(e,"src","Infrastructure","InfrastructureServiceRegistration.cs"),w(o)),await c(n.join(e,"src","Presentation","PresentationServiceRegistration.cs"),x(o)),await c(n.join(e,"src","Presentation","SystemEndpoints.cs"),v(o)),await c(n.join(e,"src","appsettings.json"),d(o)),await c(n.join(e,"src","appsettings.Development.json"),d(o)),await c(n.join(e,"tests",`${s}.Tests.csproj`),$(o)),await c(n.join(e,"tests","RuntimeSmokeTests.cs"),M(o)),await c(n.join(e,"Dockerfile"),N(o)),await c(n.join(e,"docker-compose.yml"),h(o)),await c(n.join(e,"Makefile"),V(o)),await c(n.join(e,"rapidkit"),U(o)),await c(n.join(e,"rapidkit.cmd"),O(o)),await c(n.join(e,".env.example"),`ASPNETCORE_ENVIRONMENT=Development
|
|
421
|
+
PORT=${o.port}
|
|
422
|
+
`),await c(n.join(e,".github","workflows","ci.yml"),W(o)),await c(n.join(e,".workspai","context.json"),_()),await c(n.join(e,".workspai","project.json"),E(o,c$1())),process.platform!=="win32"&&await promises.chmod(n.join(e,"rapidkit"),493),await F(e,o.skipGit),f.succeed("ASP.NET Core Web API project ready"),await L(e),console.log(i.green(`
|
|
423
|
+
\u2705 ASP.NET Core project ready!
|
|
424
|
+
`)),console.log(i.gray("Next steps:")),console.log(i.white(` cd ${s}`)),console.log(i.white(" npx workspai init")),console.log(i.white(" npx workspai dev")),console.log(i.gray(`
|
|
425
|
+
Endpoints: /health/live, /health/ready, /api/v1/system/info, /docs`)),console.log(i.gray("\u2139 RapidKit Core modules are not available for .NET projects yet."));}export{R as DEFAULT_DOTNET_PORT,C as DEFAULT_DOTNET_TARGET_FRAMEWORK,Q as generateDotnetWebApiCleanKit};
|