@gaonjs/cli 0.1.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/README.md ADDED
@@ -0,0 +1,9 @@
1
+ # @gaonjs/cli
2
+
3
+ Gaon CLI 구현 — 제너레이터·스캐폴딩. M1 에서는 로드맵 출력 스텁입니다.
4
+
5
+ > ⚠️ **개발 중 (v0.1.0 스텁).** 모든 명령은 `--json` 출력을 함께 제공합니다.
6
+
7
+ 개발자는 이 패키지를 직접 설치하지 않습니다 — [`gaon`](https://www.npmjs.com/package/gaon) 하나만 설치하세요.
8
+
9
+ - 홈페이지 / 문서: https://gaonjs.dev
@@ -0,0 +1,18 @@
1
+ export interface RoadmapReport {
2
+ readonly name: "gaon";
3
+ readonly version: string;
4
+ readonly stage: "stub";
5
+ readonly homepage: string;
6
+ readonly docs: string;
7
+ readonly milestones: readonly {
8
+ id: string;
9
+ title: string;
10
+ status: string;
11
+ }[];
12
+ }
13
+ /** `--json` 출력용 구조화 리포트. */
14
+ export declare function roadmapReport(): RoadmapReport;
15
+ /** 사람이 읽는 로드맵 텍스트. */
16
+ export declare function renderRoadmap(): string;
17
+ /** CLI 진입점. argv 는 실행 인자(process.argv.slice(2))를 받는다. */
18
+ export declare function runCli(argv: readonly string[]): void;
package/dist/index.js ADDED
@@ -0,0 +1,75 @@
1
+ /**
2
+ * @gaonjs/cli — Gaon CLI 구현.
3
+ *
4
+ * M1(현재) 스텁: 로드맵·개발 상태·참여 안내를 출력한다.
5
+ * 모든 명령은 `--json` 출력을 함께 제공한다 (CLAUDE.md §4).
6
+ * 실제 제너레이터·스캐폴딩은 로드맵 이후 마일스톤에서 구현한다.
7
+ */
8
+ import { MILESTONES, VERSION, HOMEPAGE } from "@gaonjs/core";
9
+ /** `--json` 출력용 구조화 리포트. */
10
+ export function roadmapReport() {
11
+ return {
12
+ name: "gaon",
13
+ version: VERSION,
14
+ stage: "stub",
15
+ homepage: HOMEPAGE,
16
+ docs: HOMEPAGE,
17
+ milestones: MILESTONES.map((m) => ({ id: m.id, title: m.title, status: m.status })),
18
+ };
19
+ }
20
+ /** 사람이 읽는 로드맵 텍스트. */
21
+ export function renderRoadmap() {
22
+ const lines = [];
23
+ lines.push("");
24
+ lines.push(` Gaon (가온) — AI가 개발을 가장 잘하는 Node.js 풀스택 웹 프레임웍`);
25
+ lines.push(` v${VERSION} · 개발 중 (스텁) · ${HOMEPAGE}`);
26
+ lines.push("");
27
+ lines.push(" 이 패키지는 아직 개발 초기 단계입니다. 런타임 기능은 아직 없고,");
28
+ lines.push(" 자리(스코프·이름)를 잡아 두기 위한 동작하는 스텁입니다.");
29
+ lines.push("");
30
+ lines.push(" 로드맵");
31
+ lines.push(" ──────");
32
+ for (const m of MILESTONES) {
33
+ const mark = m.status === "in-progress" ? "▶" : "·";
34
+ const tag = m.status === "in-progress" ? " (진행 중)" : "";
35
+ lines.push(` ${mark} ${m.id} ${m.title}${tag}`);
36
+ }
37
+ lines.push("");
38
+ lines.push(" 참여 · 소식");
39
+ lines.push(" ──────────");
40
+ lines.push(` 문서 / 진행 상황: ${HOMEPAGE}`);
41
+ lines.push(` JSON 출력: gaon --json`);
42
+ lines.push("");
43
+ return lines.join("\n");
44
+ }
45
+ function renderHelp() {
46
+ return [
47
+ "",
48
+ " gaon — Gaon 프레임웍 CLI (v" + VERSION + ", 스텁)",
49
+ "",
50
+ " 사용법:",
51
+ " gaon 로드맵과 개발 상태를 출력",
52
+ " gaon --json 같은 정보를 JSON 으로 출력",
53
+ " gaon --version 버전 출력",
54
+ " gaon --help 이 도움말",
55
+ "",
56
+ " 문서: " + HOMEPAGE,
57
+ "",
58
+ ].join("\n");
59
+ }
60
+ /** CLI 진입점. argv 는 실행 인자(process.argv.slice(2))를 받는다. */
61
+ export function runCli(argv) {
62
+ if (argv.includes("--help") || argv.includes("-h")) {
63
+ process.stdout.write(renderHelp() + "\n");
64
+ return;
65
+ }
66
+ if (argv.includes("--version") || argv.includes("-v")) {
67
+ process.stdout.write(VERSION + "\n");
68
+ return;
69
+ }
70
+ if (argv.includes("--json")) {
71
+ process.stdout.write(JSON.stringify(roadmapReport(), null, 2) + "\n");
72
+ return;
73
+ }
74
+ process.stdout.write(renderRoadmap() + "\n");
75
+ }
package/package.json ADDED
@@ -0,0 +1,32 @@
1
+ {
2
+ "name": "@gaonjs/cli",
3
+ "version": "0.1.0",
4
+ "description": "Gaon CLI 구현: 제너레이터·스캐폴딩·로드맵 출력 (M1 스텁)",
5
+ "type": "module",
6
+ "license": "MIT",
7
+ "homepage": "https://gaonjs.dev",
8
+ "engines": {
9
+ "node": ">=22"
10
+ },
11
+ "publishConfig": {
12
+ "access": "public"
13
+ },
14
+ "main": "dist/index.js",
15
+ "types": "dist/index.d.ts",
16
+ "exports": {
17
+ ".": {
18
+ "types": "./dist/index.d.ts",
19
+ "default": "./dist/index.js"
20
+ }
21
+ },
22
+ "files": [
23
+ "dist",
24
+ "README.md"
25
+ ],
26
+ "dependencies": {
27
+ "@gaonjs/core": "0.1.0"
28
+ },
29
+ "scripts": {
30
+ "build": "node ../../node_modules/typescript/bin/tsc -p tsconfig.json"
31
+ }
32
+ }