@mandujs/cli 0.9.18 → 0.9.20

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mandujs/cli",
3
- "version": "0.9.18",
3
+ "version": "0.9.20",
4
4
  "description": "Agent-Native Fullstack Framework - 에이전트가 코딩해도 아키텍처가 무너지지 않는 개발 OS",
5
5
  "type": "module",
6
6
  "main": "./src/main.ts",
@@ -200,5 +200,5 @@ export async function check(options: CheckOptions = {}): Promise<boolean> {
200
200
  console.log(JSON.stringify(summary, null, 2));
201
201
  }
202
202
 
203
- return options.ci ? success : success;
203
+ return options.ci ? success : true;
204
204
  }
@@ -140,7 +140,9 @@ export async function guardArch(options: GuardArchOptions = {}): Promise<boolean
140
140
 
141
141
  // Ctrl+C 핸들링
142
142
  process.on("SIGINT", () => {
143
- console.log("\n🛑 Guard stopped");
143
+ if (resolvedFormat === "console") {
144
+ console.log("\n🛑 Guard stopped");
145
+ }
144
146
  watcher.close();
145
147
  process.exit(0);
146
148
  });
@@ -71,18 +71,18 @@ export async function init(options: InitOptions = {}): Promise<boolean> {
71
71
  return false;
72
72
  }
73
73
 
74
- // Create empty generated directories
75
- await fs.mkdir(path.join(targetDir, "apps/server/generated/routes"), { recursive: true });
76
- await fs.mkdir(path.join(targetDir, "apps/web/generated/routes"), { recursive: true });
74
+ // Create .mandu directory for build output
75
+ await fs.mkdir(path.join(targetDir, ".mandu/client"), { recursive: true });
77
76
 
78
77
  console.log(`\n✅ 프로젝트 생성 완료!\n`);
79
78
  console.log(`📍 위치: ${targetDir}`);
80
79
  console.log(`\n🚀 시작하기:`);
81
80
  console.log(` cd ${projectName}`);
82
81
  console.log(` bun install`);
83
- console.log(` bun run spec`);
84
- console.log(` bun run generate`);
85
82
  console.log(` bun run dev`);
83
+ console.log(`\n📂 파일 구조:`);
84
+ console.log(` app/page.tsx → http://localhost:3000/`);
85
+ console.log(` app/api/*/route.ts → API endpoints`);
86
86
 
87
87
  return true;
88
88
  }
package/src/main.ts CHANGED
@@ -88,7 +88,8 @@ Options:
88
88
  --id <id> change rollback 시 특정 변경 ID
89
89
  --keep <n> change prune 시 유지할 스냅샷 수 (기본: 5)
90
90
  --output <path> openapi/doctor 출력 경로
91
- --format <fmt> doctor/guard/check 출력 형식: console, json, agent (기본: 자동)
91
+ --format <fmt> guard/check 출력 형식: console, json, agent (기본: 자동)
92
+ --format <fmt> doctor 출력 형식: console, json, markdown (기본: console)
92
93
  --no-llm doctor에서 LLM 사용 안 함 (템플릿 모드)
93
94
  --model <name> brain setup 시 모델 이름 (기본: llama3.2)
94
95
  --url <url> brain setup 시 Ollama URL
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Health Check API
3
+ *
4
+ * GET /api/health
5
+ */
6
+
7
+ export function GET() {
8
+ return Response.json({
9
+ status: "ok",
10
+ timestamp: new Date().toISOString(),
11
+ framework: "Mandu",
12
+ });
13
+ }
@@ -0,0 +1,60 @@
1
+ /**
2
+ * Home Page
3
+ *
4
+ * Edit this file and see changes at http://localhost:3000
5
+ */
6
+
7
+ export default function HomePage() {
8
+ return (
9
+ <html lang="ko">
10
+ <head>
11
+ <meta charSet="UTF-8" />
12
+ <meta name="viewport" content="width=device-width, initial-scale=1.0" />
13
+ <title>Mandu App</title>
14
+ <style>{`
15
+ body {
16
+ font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
17
+ display: flex;
18
+ justify-content: center;
19
+ align-items: center;
20
+ min-height: 100vh;
21
+ margin: 0;
22
+ background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
23
+ color: white;
24
+ }
25
+ .container {
26
+ text-align: center;
27
+ padding: 2rem;
28
+ }
29
+ h1 {
30
+ font-size: 3rem;
31
+ margin-bottom: 1rem;
32
+ }
33
+ p {
34
+ font-size: 1.2rem;
35
+ opacity: 0.9;
36
+ }
37
+ code {
38
+ background: rgba(255,255,255,0.2);
39
+ padding: 0.2rem 0.5rem;
40
+ border-radius: 4px;
41
+ }
42
+ a {
43
+ color: white;
44
+ text-decoration: underline;
45
+ }
46
+ `}</style>
47
+ </head>
48
+ <body>
49
+ <div className="container">
50
+ <h1>🥟 Mandu</h1>
51
+ <p>Welcome to your new Mandu project!</p>
52
+ <p>Edit <code>app/page.tsx</code> to get started.</p>
53
+ <p>
54
+ <a href="/api/health">Check API Health →</a>
55
+ </p>
56
+ </div>
57
+ </body>
58
+ </html>
59
+ );
60
+ }
@@ -5,19 +5,15 @@
5
5
  "scripts": {
6
6
  "dev": "mandu dev",
7
7
  "build": "mandu build",
8
- "generate": "mandu generate",
9
- "guard": "mandu guard",
10
- "spec": "mandu spec-upsert",
11
- "test": "bun test",
12
- "test:watch": "bun test --watch"
8
+ "test": "bun test"
13
9
  },
14
10
  "dependencies": {
15
- "@mandujs/core": "^0.4.0",
11
+ "@mandujs/core": "^0.9.38",
16
12
  "react": "^18.2.0",
17
13
  "react-dom": "^18.2.0"
18
14
  },
19
15
  "devDependencies": {
20
- "@mandujs/cli": "^0.4.0",
16
+ "@mandujs/cli": "^0.9.18",
21
17
  "@types/react": "^18.2.0",
22
18
  "@types/react-dom": "^18.2.0",
23
19
  "typescript": "^5.0.0"
@@ -1,18 +1,4 @@
1
1
  {
2
- "version": 1,
3
- "routes": [
4
- {
5
- "id": "home",
6
- "pattern": "/",
7
- "kind": "page",
8
- "module": "apps/server/generated/routes/home.route.ts",
9
- "componentModule": "apps/web/generated/routes/home.route.tsx"
10
- },
11
- {
12
- "id": "health",
13
- "pattern": "/api/health",
14
- "kind": "api",
15
- "module": "apps/server/generated/routes/health.route.ts"
16
- }
17
- ]
2
+ "version": 2,
3
+ "routes": []
18
4
  }