aiag-cli 1.6.2 → 1.7.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 +11 -11
- package/dist/cli.js +1 -0
- package/dist/cli.js.map +1 -1
- package/dist/commands/auto.d.ts.map +1 -1
- package/dist/commands/auto.js +180 -20
- package/dist/commands/auto.js.map +1 -1
- package/dist/commands/init.d.ts +1 -0
- package/dist/commands/init.d.ts.map +1 -1
- package/dist/commands/init.js +246 -170
- package/dist/commands/init.js.map +1 -1
- package/dist/utils/claudeMd.d.ts +49 -0
- package/dist/utils/claudeMd.d.ts.map +1 -0
- package/dist/utils/claudeMd.js +413 -0
- package/dist/utils/claudeMd.js.map +1 -0
- package/dist/utils/initializerAgent.d.ts +24 -0
- package/dist/utils/initializerAgent.d.ts.map +1 -0
- package/dist/utils/initializerAgent.js +182 -0
- package/dist/utils/initializerAgent.js.map +1 -0
- package/dist/utils/messages.d.ts +184 -0
- package/dist/utils/messages.d.ts.map +1 -0
- package/dist/utils/messages.js +232 -0
- package/dist/utils/messages.js.map +1 -0
- package/dist/utils/output.d.ts +23 -0
- package/dist/utils/output.d.ts.map +1 -1
- package/dist/utils/output.js +39 -0
- package/dist/utils/output.js.map +1 -1
- package/dist/utils/prd.d.ts +39 -0
- package/dist/utils/prd.d.ts.map +1 -0
- package/dist/utils/prd.js +77 -0
- package/dist/utils/prd.js.map +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,184 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 한국어 메시지 관리 시스템
|
|
3
|
+
* 모든 CLI 출력 메시지를 중앙에서 관리
|
|
4
|
+
*/
|
|
5
|
+
export declare const messages: {
|
|
6
|
+
common: {
|
|
7
|
+
success: string;
|
|
8
|
+
error: string;
|
|
9
|
+
warning: string;
|
|
10
|
+
loading: string;
|
|
11
|
+
notInitialized: string;
|
|
12
|
+
runInitFirst: string;
|
|
13
|
+
};
|
|
14
|
+
init: {
|
|
15
|
+
header: string;
|
|
16
|
+
alreadyInitialized: string;
|
|
17
|
+
useForce: string;
|
|
18
|
+
noPrdFound: string;
|
|
19
|
+
prdGuidance: {
|
|
20
|
+
title: string;
|
|
21
|
+
createFirst: string;
|
|
22
|
+
files: string[];
|
|
23
|
+
whatToInclude: string;
|
|
24
|
+
includes: string[];
|
|
25
|
+
orSkip: string;
|
|
26
|
+
skipCommand: string;
|
|
27
|
+
};
|
|
28
|
+
foundPrd: string;
|
|
29
|
+
runningInitializer: string;
|
|
30
|
+
progress: {
|
|
31
|
+
creatingStructure: string;
|
|
32
|
+
readingPrd: string;
|
|
33
|
+
analyzing: string;
|
|
34
|
+
decomposing: string;
|
|
35
|
+
generatingClaudeMd: string;
|
|
36
|
+
validating: string;
|
|
37
|
+
};
|
|
38
|
+
complete: {
|
|
39
|
+
success: string;
|
|
40
|
+
filesCreated: string;
|
|
41
|
+
featureListDesc: string;
|
|
42
|
+
progressDesc: string;
|
|
43
|
+
claudeMdDesc: string;
|
|
44
|
+
nextSteps: string;
|
|
45
|
+
steps: string[];
|
|
46
|
+
};
|
|
47
|
+
files: {
|
|
48
|
+
featureList: string;
|
|
49
|
+
progress: string;
|
|
50
|
+
initSh: string;
|
|
51
|
+
sessionContext: string;
|
|
52
|
+
templates: string;
|
|
53
|
+
vscode: string;
|
|
54
|
+
claudeMd: string;
|
|
55
|
+
};
|
|
56
|
+
};
|
|
57
|
+
status: {
|
|
58
|
+
header: string;
|
|
59
|
+
notInitialized: string;
|
|
60
|
+
progress: string;
|
|
61
|
+
byCategory: string;
|
|
62
|
+
byPriority: string;
|
|
63
|
+
recentActivity: string;
|
|
64
|
+
noFeatures: string;
|
|
65
|
+
completedFeatures: string;
|
|
66
|
+
remainingFeatures: string;
|
|
67
|
+
lastUpdate: string;
|
|
68
|
+
};
|
|
69
|
+
next: {
|
|
70
|
+
header: string;
|
|
71
|
+
notInitialized: string;
|
|
72
|
+
noFeaturesAvailable: string;
|
|
73
|
+
allComplete: string;
|
|
74
|
+
recommended: string;
|
|
75
|
+
startWith: string;
|
|
76
|
+
category: string;
|
|
77
|
+
priority: string;
|
|
78
|
+
description: string;
|
|
79
|
+
acceptanceCriteria: string;
|
|
80
|
+
};
|
|
81
|
+
work: {
|
|
82
|
+
header: string;
|
|
83
|
+
notInitialized: string;
|
|
84
|
+
notFound: string;
|
|
85
|
+
alreadyComplete: string;
|
|
86
|
+
starting: string;
|
|
87
|
+
sessionUpdated: string;
|
|
88
|
+
promptReady: string;
|
|
89
|
+
feature: string;
|
|
90
|
+
status: string;
|
|
91
|
+
testCommand: string;
|
|
92
|
+
};
|
|
93
|
+
auto: {
|
|
94
|
+
header: string;
|
|
95
|
+
notInitialized: string;
|
|
96
|
+
noFeatures: string;
|
|
97
|
+
starting: string;
|
|
98
|
+
loopMode: string;
|
|
99
|
+
resumeMode: string;
|
|
100
|
+
processing: string;
|
|
101
|
+
completed: string;
|
|
102
|
+
skipped: string;
|
|
103
|
+
currentFeature: string;
|
|
104
|
+
progress: string;
|
|
105
|
+
};
|
|
106
|
+
test: {
|
|
107
|
+
header: string;
|
|
108
|
+
notInitialized: string;
|
|
109
|
+
notFound: string;
|
|
110
|
+
noTestCommand: string;
|
|
111
|
+
running: string;
|
|
112
|
+
passed: string;
|
|
113
|
+
failed: string;
|
|
114
|
+
allPassed: string;
|
|
115
|
+
summary: string;
|
|
116
|
+
total: string;
|
|
117
|
+
passed_count: string;
|
|
118
|
+
failed_count: string;
|
|
119
|
+
};
|
|
120
|
+
complete: {
|
|
121
|
+
header: string;
|
|
122
|
+
notInitialized: string;
|
|
123
|
+
notFound: string;
|
|
124
|
+
alreadyComplete: string;
|
|
125
|
+
testRequired: string;
|
|
126
|
+
skipTest: string;
|
|
127
|
+
marked: string;
|
|
128
|
+
runningTest: string;
|
|
129
|
+
testPassed: string;
|
|
130
|
+
updated: string;
|
|
131
|
+
};
|
|
132
|
+
commit: {
|
|
133
|
+
header: string;
|
|
134
|
+
notInitialized: string;
|
|
135
|
+
noChanges: string;
|
|
136
|
+
analyzing: string;
|
|
137
|
+
generatingMessage: string;
|
|
138
|
+
committed: string;
|
|
139
|
+
};
|
|
140
|
+
session: {
|
|
141
|
+
start: {
|
|
142
|
+
header: string;
|
|
143
|
+
notInitialized: string;
|
|
144
|
+
started: string;
|
|
145
|
+
checking: string;
|
|
146
|
+
ready: string;
|
|
147
|
+
};
|
|
148
|
+
end: {
|
|
149
|
+
header: string;
|
|
150
|
+
notInitialized: string;
|
|
151
|
+
ended: string;
|
|
152
|
+
summary: string;
|
|
153
|
+
featuresCompleted: string;
|
|
154
|
+
nextSession: string;
|
|
155
|
+
};
|
|
156
|
+
};
|
|
157
|
+
validate: {
|
|
158
|
+
header: string;
|
|
159
|
+
notInitialized: string;
|
|
160
|
+
valid: string;
|
|
161
|
+
invalid: string;
|
|
162
|
+
errors: string;
|
|
163
|
+
warnings: string;
|
|
164
|
+
checking: string;
|
|
165
|
+
issuesFound: string;
|
|
166
|
+
};
|
|
167
|
+
errors: {
|
|
168
|
+
fileNotFound: string;
|
|
169
|
+
invalidJson: string;
|
|
170
|
+
commandFailed: string;
|
|
171
|
+
unknownError: string;
|
|
172
|
+
};
|
|
173
|
+
};
|
|
174
|
+
/**
|
|
175
|
+
* 메시지 템플릿에 매개변수를 치환
|
|
176
|
+
* @example formatMessage("기능 {count}개 생성됨", { count: 47 })
|
|
177
|
+
*/
|
|
178
|
+
export declare function formatMessage(template: string, params: Record<string, string | number>): string;
|
|
179
|
+
/**
|
|
180
|
+
* 중첩된 객체에서 키 경로로 메시지 가져오기
|
|
181
|
+
* @example getMessage("init.header") → "AIAG 프로젝트 초기화"
|
|
182
|
+
*/
|
|
183
|
+
export declare function getMessage(keyPath: string): string;
|
|
184
|
+
//# sourceMappingURL=messages.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"messages.d.ts","sourceRoot":"","sources":["../../src/utils/messages.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,eAAO,MAAM,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAuNpB,CAAC;AAEF;;;GAGG;AACH,wBAAgB,aAAa,CAC3B,QAAQ,EAAE,MAAM,EAChB,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAAC,GACtC,MAAM,CAKR;AAED;;;GAGG;AACH,wBAAgB,UAAU,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CAalD"}
|
|
@@ -0,0 +1,232 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 한국어 메시지 관리 시스템
|
|
3
|
+
* 모든 CLI 출력 메시지를 중앙에서 관리
|
|
4
|
+
*/
|
|
5
|
+
export const messages = {
|
|
6
|
+
// 공통 메시지
|
|
7
|
+
common: {
|
|
8
|
+
success: '성공',
|
|
9
|
+
error: '오류',
|
|
10
|
+
warning: '경고',
|
|
11
|
+
loading: '처리 중...',
|
|
12
|
+
notInitialized: 'AIAG가 초기화되지 않았습니다.',
|
|
13
|
+
runInitFirst: '"aiag init"를 먼저 실행하세요.',
|
|
14
|
+
},
|
|
15
|
+
// Init 명령 메시지
|
|
16
|
+
init: {
|
|
17
|
+
header: 'AIAG 프로젝트 초기화',
|
|
18
|
+
alreadyInitialized: 'AIAG가 이미 초기화되어 있습니다.',
|
|
19
|
+
useForce: '--force 옵션을 사용하여 재초기화할 수 있습니다.',
|
|
20
|
+
// PRD 관련
|
|
21
|
+
noPrdFound: 'PRD를 찾을 수 없습니다',
|
|
22
|
+
prdGuidance: {
|
|
23
|
+
title: 'AIAG는 Product Requirements Document(PRD)와 함께 사용할 때 최상의 결과를 제공합니다.',
|
|
24
|
+
createFirst: '먼저 다음 파일 중 하나를 생성하세요:',
|
|
25
|
+
files: [
|
|
26
|
+
'PRD.md (권장)',
|
|
27
|
+
'REQUIREMENTS.md',
|
|
28
|
+
'docs/prd.md'
|
|
29
|
+
],
|
|
30
|
+
whatToInclude: 'PRD에 포함할 내용:',
|
|
31
|
+
includes: [
|
|
32
|
+
'프로젝트 개요 및 목표',
|
|
33
|
+
'핵심 기능 및 요구사항',
|
|
34
|
+
'기술적 제약사항',
|
|
35
|
+
'성공 기준'
|
|
36
|
+
],
|
|
37
|
+
orSkip: '또는 다음 명령으로 최소 초기화만 수행:',
|
|
38
|
+
skipCommand: 'aiag init --minimal'
|
|
39
|
+
},
|
|
40
|
+
foundPrd: 'PRD를 찾았습니다',
|
|
41
|
+
runningInitializer: 'Initializer Agent 실행 중...',
|
|
42
|
+
// 진행 상태
|
|
43
|
+
progress: {
|
|
44
|
+
creatingStructure: '.aiag/ 디렉토리 구조 생성 중...',
|
|
45
|
+
readingPrd: 'PRD 읽는 중...',
|
|
46
|
+
analyzing: '요구사항 분석 중...',
|
|
47
|
+
decomposing: '기능으로 분해 중...',
|
|
48
|
+
generatingClaudeMd: 'CLAUDE.md 생성 중...',
|
|
49
|
+
validating: 'Feature list 유효성 검사 중...',
|
|
50
|
+
},
|
|
51
|
+
// 완료 메시지
|
|
52
|
+
complete: {
|
|
53
|
+
success: 'AIAG 초기화 완료!',
|
|
54
|
+
filesCreated: '생성된 파일:',
|
|
55
|
+
featureListDesc: '작업 목록 (무엇을 할지)',
|
|
56
|
+
progressDesc: '진행 기록 (무엇을 했는지)',
|
|
57
|
+
claudeMdDesc: 'Claude 작업 지침 (어떻게 할지)',
|
|
58
|
+
nextSteps: '다음 단계:',
|
|
59
|
+
steps: [
|
|
60
|
+
'CLAUDE.md 검토 및 필요시 수정',
|
|
61
|
+
'.aiag/feature_list.json 검토',
|
|
62
|
+
"'aiag status' 실행하여 기능 분포 확인",
|
|
63
|
+
"'aiag next' 실행하여 첫 번째 기능 시작",
|
|
64
|
+
"(선택) 커밋: git add .aiag CLAUDE.md && git commit -m \"feat: AIAG 초기화\""
|
|
65
|
+
]
|
|
66
|
+
},
|
|
67
|
+
// 파일 생성 로그
|
|
68
|
+
files: {
|
|
69
|
+
featureList: '.aiag/feature_list.json',
|
|
70
|
+
progress: '.aiag/progress.md',
|
|
71
|
+
initSh: '.aiag/init.sh',
|
|
72
|
+
sessionContext: '.aiag/session_context.md',
|
|
73
|
+
templates: '.aiag/templates/',
|
|
74
|
+
vscode: '.vscode/settings.json',
|
|
75
|
+
claudeMd: 'CLAUDE.md'
|
|
76
|
+
}
|
|
77
|
+
},
|
|
78
|
+
// Status 명령 메시지
|
|
79
|
+
status: {
|
|
80
|
+
header: '프로젝트 진행 상황',
|
|
81
|
+
notInitialized: 'AIAG가 초기화되지 않았습니다.',
|
|
82
|
+
progress: '전체 진행률',
|
|
83
|
+
byCategory: '카테고리별 진행률',
|
|
84
|
+
byPriority: '우선순위별 진행률',
|
|
85
|
+
recentActivity: '최근 활동',
|
|
86
|
+
noFeatures: '기능이 정의되지 않았습니다.',
|
|
87
|
+
completedFeatures: '완료된 기능',
|
|
88
|
+
remainingFeatures: '남은 기능',
|
|
89
|
+
lastUpdate: '마지막 업데이트',
|
|
90
|
+
},
|
|
91
|
+
// Next 명령 메시지
|
|
92
|
+
next: {
|
|
93
|
+
header: '다음 작업 추천',
|
|
94
|
+
notInitialized: 'AIAG가 초기화되지 않았습니다.',
|
|
95
|
+
noFeaturesAvailable: '작업 가능한 기능이 없습니다.',
|
|
96
|
+
allComplete: '🎉 모든 기능이 완료되었습니다!',
|
|
97
|
+
recommended: '추천 기능:',
|
|
98
|
+
startWith: '다음 명령으로 시작하세요:',
|
|
99
|
+
category: '카테고리',
|
|
100
|
+
priority: '우선순위',
|
|
101
|
+
description: '설명',
|
|
102
|
+
acceptanceCriteria: '완료 조건',
|
|
103
|
+
},
|
|
104
|
+
// Work 명령 메시지
|
|
105
|
+
work: {
|
|
106
|
+
header: '기능 작업 시작',
|
|
107
|
+
notInitialized: 'AIAG가 초기화되지 않았습니다.',
|
|
108
|
+
notFound: '기능을 찾을 수 없습니다: {id}',
|
|
109
|
+
alreadyComplete: '이 기능은 이미 완료되었습니다: {id}',
|
|
110
|
+
starting: '작업 시작 중: {id}',
|
|
111
|
+
sessionUpdated: '세션 컨텍스트가 업데이트되었습니다.',
|
|
112
|
+
promptReady: '작업 프롬프트가 준비되었습니다.',
|
|
113
|
+
feature: '기능',
|
|
114
|
+
status: '상태',
|
|
115
|
+
testCommand: '테스트 명령',
|
|
116
|
+
},
|
|
117
|
+
// Auto 명령 메시지
|
|
118
|
+
auto: {
|
|
119
|
+
header: 'AI Agent 자동 실행 모드',
|
|
120
|
+
notInitialized: 'AIAG가 초기화되지 않았습니다.',
|
|
121
|
+
noFeatures: '작업할 기능이 없습니다.',
|
|
122
|
+
starting: 'AI Agent 실행 중... (최대 {count}개 기능)',
|
|
123
|
+
loopMode: '🔄 무한 루프 모드 활성화 (Ctrl+C로 중단)',
|
|
124
|
+
resumeMode: '▶️ 이어서 시작 모드 활성화',
|
|
125
|
+
processing: '처리 중',
|
|
126
|
+
completed: '완료',
|
|
127
|
+
skipped: '건너뜀',
|
|
128
|
+
currentFeature: '현재 작업',
|
|
129
|
+
progress: '진행률',
|
|
130
|
+
},
|
|
131
|
+
// Test 명령 메시지
|
|
132
|
+
test: {
|
|
133
|
+
header: '기능 테스트 실행',
|
|
134
|
+
notInitialized: 'AIAG가 초기화되지 않았습니다.',
|
|
135
|
+
notFound: '기능을 찾을 수 없습니다: {id}',
|
|
136
|
+
noTestCommand: '테스트 명령이 정의되지 않았습니다.',
|
|
137
|
+
running: '테스트 실행 중...',
|
|
138
|
+
passed: '✅ 테스트 통과',
|
|
139
|
+
failed: '❌ 테스트 실패',
|
|
140
|
+
allPassed: '모든 테스트 통과!',
|
|
141
|
+
summary: '테스트 요약',
|
|
142
|
+
total: '전체',
|
|
143
|
+
passed_count: '통과',
|
|
144
|
+
failed_count: '실패',
|
|
145
|
+
},
|
|
146
|
+
// Complete 명령 메시지
|
|
147
|
+
complete: {
|
|
148
|
+
header: '기능 완료 처리',
|
|
149
|
+
notInitialized: 'AIAG가 초기화되지 않았습니다.',
|
|
150
|
+
notFound: '기능을 찾을 수 없습니다: {id}',
|
|
151
|
+
alreadyComplete: '이미 완료된 기능입니다.',
|
|
152
|
+
testRequired: '완료 처리 전에 테스트를 통과해야 합니다.',
|
|
153
|
+
skipTest: '--skip-test 옵션으로 테스트를 건너뛸 수 있습니다.',
|
|
154
|
+
marked: '기능이 완료 처리되었습니다: {id}',
|
|
155
|
+
runningTest: '테스트 실행 중...',
|
|
156
|
+
testPassed: '테스트 통과!',
|
|
157
|
+
updated: 'feature_list.json 업데이트됨',
|
|
158
|
+
},
|
|
159
|
+
// Commit 명령 메시지
|
|
160
|
+
commit: {
|
|
161
|
+
header: 'Git 커밋',
|
|
162
|
+
notInitialized: 'AIAG가 초기화되지 않았습니다.',
|
|
163
|
+
noChanges: '커밋할 변경사항이 없습니다.',
|
|
164
|
+
analyzing: '변경사항 분석 중...',
|
|
165
|
+
generatingMessage: '커밋 메시지 생성 중...',
|
|
166
|
+
committed: '커밋 완료',
|
|
167
|
+
},
|
|
168
|
+
// Session 명령 메시지
|
|
169
|
+
session: {
|
|
170
|
+
start: {
|
|
171
|
+
header: '세션 시작',
|
|
172
|
+
notInitialized: 'AIAG가 초기화되지 않았습니다.',
|
|
173
|
+
started: '새 세션이 시작되었습니다.',
|
|
174
|
+
checking: '환경 확인 중...',
|
|
175
|
+
ready: '개발 환경 준비 완료',
|
|
176
|
+
},
|
|
177
|
+
end: {
|
|
178
|
+
header: '세션 종료',
|
|
179
|
+
notInitialized: 'AIAG가 초기화되지 않았습니다.',
|
|
180
|
+
ended: '세션이 종료되었습니다.',
|
|
181
|
+
summary: '세션 요약',
|
|
182
|
+
featuresCompleted: '완료된 기능',
|
|
183
|
+
nextSession: '다음 세션 시 권장사항',
|
|
184
|
+
}
|
|
185
|
+
},
|
|
186
|
+
// Validate 명령 메시지
|
|
187
|
+
validate: {
|
|
188
|
+
header: 'Feature List 유효성 검사',
|
|
189
|
+
notInitialized: 'AIAG가 초기화되지 않았습니다.',
|
|
190
|
+
valid: '✅ Feature list가 유효합니다.',
|
|
191
|
+
invalid: '❌ Feature list에 문제가 있습니다.',
|
|
192
|
+
errors: '오류',
|
|
193
|
+
warnings: '경고',
|
|
194
|
+
checking: '유효성 검사 중...',
|
|
195
|
+
issuesFound: '개의 문제 발견',
|
|
196
|
+
},
|
|
197
|
+
// 에러 메시지
|
|
198
|
+
errors: {
|
|
199
|
+
fileNotFound: '파일을 찾을 수 없습니다: {path}',
|
|
200
|
+
invalidJson: 'JSON 파싱 오류: {path}',
|
|
201
|
+
commandFailed: '명령 실행 실패: {command}',
|
|
202
|
+
unknownError: '알 수 없는 오류가 발생했습니다.',
|
|
203
|
+
}
|
|
204
|
+
};
|
|
205
|
+
/**
|
|
206
|
+
* 메시지 템플릿에 매개변수를 치환
|
|
207
|
+
* @example formatMessage("기능 {count}개 생성됨", { count: 47 })
|
|
208
|
+
*/
|
|
209
|
+
export function formatMessage(template, params) {
|
|
210
|
+
return template.replace(/\{(\w+)\}/g, (_, key) => {
|
|
211
|
+
const value = params[key];
|
|
212
|
+
return value !== undefined ? String(value) : `{${key}}`;
|
|
213
|
+
});
|
|
214
|
+
}
|
|
215
|
+
/**
|
|
216
|
+
* 중첩된 객체에서 키 경로로 메시지 가져오기
|
|
217
|
+
* @example getMessage("init.header") → "AIAG 프로젝트 초기화"
|
|
218
|
+
*/
|
|
219
|
+
export function getMessage(keyPath) {
|
|
220
|
+
const keys = keyPath.split('.');
|
|
221
|
+
let result = messages;
|
|
222
|
+
for (const key of keys) {
|
|
223
|
+
if (result && typeof result === 'object' && key in result) {
|
|
224
|
+
result = result[key];
|
|
225
|
+
}
|
|
226
|
+
else {
|
|
227
|
+
return keyPath; // 키를 찾지 못하면 원래 키 반환
|
|
228
|
+
}
|
|
229
|
+
}
|
|
230
|
+
return typeof result === 'string' ? result : keyPath;
|
|
231
|
+
}
|
|
232
|
+
//# sourceMappingURL=messages.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"messages.js","sourceRoot":"","sources":["../../src/utils/messages.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,MAAM,CAAC,MAAM,QAAQ,GAAG;IACtB,SAAS;IACT,MAAM,EAAE;QACN,OAAO,EAAE,IAAI;QACb,KAAK,EAAE,IAAI;QACX,OAAO,EAAE,IAAI;QACb,OAAO,EAAE,SAAS;QAClB,cAAc,EAAE,oBAAoB;QACpC,YAAY,EAAE,wBAAwB;KACvC;IAED,cAAc;IACd,IAAI,EAAE;QACJ,MAAM,EAAE,eAAe;QACvB,kBAAkB,EAAE,sBAAsB;QAC1C,QAAQ,EAAE,gCAAgC;QAE1C,SAAS;QACT,UAAU,EAAE,gBAAgB;QAC5B,WAAW,EAAE;YACX,KAAK,EAAE,mEAAmE;YAC1E,WAAW,EAAE,uBAAuB;YACpC,KAAK,EAAE;gBACL,aAAa;gBACb,iBAAiB;gBACjB,aAAa;aACd;YACD,aAAa,EAAE,cAAc;YAC7B,QAAQ,EAAE;gBACR,cAAc;gBACd,cAAc;gBACd,UAAU;gBACV,OAAO;aACR;YACD,MAAM,EAAE,wBAAwB;YAChC,WAAW,EAAE,qBAAqB;SACnC;QAED,QAAQ,EAAE,YAAY;QACtB,kBAAkB,EAAE,2BAA2B;QAE/C,QAAQ;QACR,QAAQ,EAAE;YACR,iBAAiB,EAAE,wBAAwB;YAC3C,UAAU,EAAE,aAAa;YACzB,SAAS,EAAE,cAAc;YACzB,WAAW,EAAE,cAAc;YAC3B,kBAAkB,EAAE,mBAAmB;YACvC,UAAU,EAAE,0BAA0B;SACvC;QAED,SAAS;QACT,QAAQ,EAAE;YACR,OAAO,EAAE,cAAc;YACvB,YAAY,EAAE,SAAS;YACvB,eAAe,EAAE,gBAAgB;YACjC,YAAY,EAAE,iBAAiB;YAC/B,YAAY,EAAE,uBAAuB;YACrC,SAAS,EAAE,Q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O,MAAM,KAAK,QAAQ,IAAI,GAAG,IAAI,MAAM,EAAE,CAAC;YAC1D,MAAM,GAAG,MAAM,CAAC,GAAG,CAAC,CAAC;QACvB,CAAC;aAAM,CAAC;YACN,OAAO,OAAO,CAAC,CAAC,oBAAoB;QACtC,CAAC;IACH,CAAC;IAED,OAAO,OAAO,MAAM,KAAK,QAAQ,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,OAAO,CAAC;AACvD,CAAC"}
|
package/dist/utils/output.d.ts
CHANGED
|
@@ -1,11 +1,14 @@
|
|
|
1
|
+
import { messages, formatMessage, getMessage } from './messages.js';
|
|
1
2
|
/**
|
|
2
3
|
* Output utilities for CLI
|
|
3
4
|
*/
|
|
5
|
+
export { messages, formatMessage, getMessage };
|
|
4
6
|
export declare const colors: {
|
|
5
7
|
success: import("chalk").ChalkInstance;
|
|
6
8
|
error: import("chalk").ChalkInstance;
|
|
7
9
|
warning: import("chalk").ChalkInstance;
|
|
8
10
|
info: import("chalk").ChalkInstance;
|
|
11
|
+
cyan: import("chalk").ChalkInstance;
|
|
9
12
|
dim: import("chalk").ChalkInstance;
|
|
10
13
|
bold: import("chalk").ChalkInstance;
|
|
11
14
|
};
|
|
@@ -68,4 +71,24 @@ export declare function printInfo(message: string): void;
|
|
|
68
71
|
* Print a key-value pair
|
|
69
72
|
*/
|
|
70
73
|
export declare function printKeyValue(key: string, value: string | number): void;
|
|
74
|
+
/**
|
|
75
|
+
* Print a message using key path
|
|
76
|
+
* @example printMessageByKey('init.header') → "AIAG 프로젝트 초기화"
|
|
77
|
+
*/
|
|
78
|
+
export declare function printMessageByKey(keyPath: string, params?: Record<string, string | number>): void;
|
|
79
|
+
/**
|
|
80
|
+
* Print a list of items with bullets
|
|
81
|
+
*/
|
|
82
|
+
export declare function printList(items: string[], options?: {
|
|
83
|
+
indent?: number;
|
|
84
|
+
bullet?: string;
|
|
85
|
+
}): void;
|
|
86
|
+
/**
|
|
87
|
+
* Print a divider line
|
|
88
|
+
*/
|
|
89
|
+
export declare function printDivider(char?: string, length?: number): void;
|
|
90
|
+
/**
|
|
91
|
+
* Print empty lines
|
|
92
|
+
*/
|
|
93
|
+
export declare function printEmptyLine(count?: number): void;
|
|
71
94
|
//# sourceMappingURL=output.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"output.d.ts","sourceRoot":"","sources":["../../src/utils/output.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"output.d.ts","sourceRoot":"","sources":["../../src/utils/output.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAE,aAAa,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAEpE;;GAEG;AAGH,OAAO,EAAE,QAAQ,EAAE,aAAa,EAAE,UAAU,EAAE,CAAC;AAE/C,eAAO,MAAM,MAAM;;;;;;;;CAQlB,CAAC;AAEF,eAAO,MAAM,KAAK;;;;;;;;;;;CAWjB,CAAC;AAEF;;GAEG;AACH,wBAAgB,WAAW,CACzB,UAAU,EAAE,MAAM,EAClB,KAAK,GAAE,MAAW,EAClB,MAAM,GAAE,MAAY,EACpB,KAAK,GAAE,MAAY,GAClB,MAAM,CAQR;AAED;;GAEG;AACH,wBAAgB,aAAa,CAAC,OAAO,EAAE;IACrC,EAAE,EAAE,MAAM,CAAC;IACX,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,kBAAkB,EAAE,MAAM,EAAE,CAAC;IAC7B,MAAM,EAAE,OAAO,CAAC;CACjB,GAAG,MAAM,CAiBT;AAED;;GAEG;AACH,wBAAgB,gBAAgB,CAAC,QAAQ,EAAE,MAAM,GAAG,CAAC,IAAI,EAAE,MAAM,KAAK,MAAM,CAa3E;AAED;;GAEG;AACH,wBAAgB,WAAW,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,CAI/C;AAED;;GAEG;AACH,wBAAgB,YAAY,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,CAGhD;AAED;;GAEG;AACH,wBAAgB,YAAY,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAElD;AAED;;GAEG;AACH,wBAAgB,UAAU,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAEhD;AAED;;GAEG;AACH,wBAAgB,YAAY,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAElD;AAED;;GAEG;AACH,wBAAgB,SAAS,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAE/C;AAED;;GAEG;AACH,wBAAgB,aAAa,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAEvE;AAED;;;GAGG;AACH,wBAAgB,iBAAiB,CAAC,OAAO,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAAC,GAAG,IAAI,CAMjG;AAED;;GAEG;AACH,wBAAgB,SAAS,CAAC,KAAK,EAAE,MAAM,EAAE,EAAE,OAAO,GAAE;IAAE,MAAM,CAAC,EAAE,MAAM,CAAC;IAAC,MAAM,CAAC,EAAE,MAAM,CAAA;CAAO,GAAG,IAAI,CAOnG;AAED;;GAEG;AACH,wBAAgB,YAAY,CAAC,IAAI,GAAE,MAAY,EAAE,MAAM,GAAE,MAAW,GAAG,IAAI,CAE1E;AAED;;GAEG;AACH,wBAAgB,cAAc,CAAC,KAAK,GAAE,MAAU,GAAG,IAAI,CAItD"}
|
package/dist/utils/output.js
CHANGED
|
@@ -1,12 +1,16 @@
|
|
|
1
1
|
import chalk from 'chalk';
|
|
2
|
+
import { messages, formatMessage, getMessage } from './messages.js';
|
|
2
3
|
/**
|
|
3
4
|
* Output utilities for CLI
|
|
4
5
|
*/
|
|
6
|
+
// 메시지 시스템 re-export
|
|
7
|
+
export { messages, formatMessage, getMessage };
|
|
5
8
|
export const colors = {
|
|
6
9
|
success: chalk.green,
|
|
7
10
|
error: chalk.red,
|
|
8
11
|
warning: chalk.yellow,
|
|
9
12
|
info: chalk.blue,
|
|
13
|
+
cyan: chalk.cyan,
|
|
10
14
|
dim: chalk.dim,
|
|
11
15
|
bold: chalk.bold,
|
|
12
16
|
};
|
|
@@ -112,4 +116,39 @@ export function printInfo(message) {
|
|
|
112
116
|
export function printKeyValue(key, value) {
|
|
113
117
|
console.log(` ${colors.dim(key + ':')} ${value}`);
|
|
114
118
|
}
|
|
119
|
+
/**
|
|
120
|
+
* Print a message using key path
|
|
121
|
+
* @example printMessageByKey('init.header') → "AIAG 프로젝트 초기화"
|
|
122
|
+
*/
|
|
123
|
+
export function printMessageByKey(keyPath, params) {
|
|
124
|
+
let message = getMessage(keyPath);
|
|
125
|
+
if (params) {
|
|
126
|
+
message = formatMessage(message, params);
|
|
127
|
+
}
|
|
128
|
+
console.log(message);
|
|
129
|
+
}
|
|
130
|
+
/**
|
|
131
|
+
* Print a list of items with bullets
|
|
132
|
+
*/
|
|
133
|
+
export function printList(items, options = {}) {
|
|
134
|
+
const indent = ' '.repeat(options.indent || 2);
|
|
135
|
+
const bullet = options.bullet || icons.bullet;
|
|
136
|
+
for (const item of items) {
|
|
137
|
+
console.log(`${indent}${bullet} ${item}`);
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
/**
|
|
141
|
+
* Print a divider line
|
|
142
|
+
*/
|
|
143
|
+
export function printDivider(char = '─', length = 50) {
|
|
144
|
+
console.log(colors.dim(char.repeat(length)));
|
|
145
|
+
}
|
|
146
|
+
/**
|
|
147
|
+
* Print empty lines
|
|
148
|
+
*/
|
|
149
|
+
export function printEmptyLine(count = 1) {
|
|
150
|
+
for (let i = 0; i < count; i++) {
|
|
151
|
+
console.log('');
|
|
152
|
+
}
|
|
153
|
+
}
|
|
115
154
|
//# sourceMappingURL=output.js.map
|
package/dist/utils/output.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"output.js","sourceRoot":"","sources":["../../src/utils/output.ts"],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AAM,GAAG,MAAM,IAAI,IAAI,EAAE,CAAC,CAAC;IAC5C,CAAC;AACH,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,YAAY,CAAC,OAAe,GAAG,EAAE,SAAiB,EAAE;IAClE,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC;AAC/C,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,cAAc,CAAC,QAAgB,CAAC;IAC9C,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,KAAK,EAAE,CAAC,EAAE,EAAE,CAAC;QAC/B,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;IAClB,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* PRD (Product Requirements Document) 관리 유틸리티
|
|
3
|
+
*/
|
|
4
|
+
/**
|
|
5
|
+
* PRD 파일 검색 우선순위 목록
|
|
6
|
+
*/
|
|
7
|
+
export declare const PRD_CANDIDATES: string[];
|
|
8
|
+
/**
|
|
9
|
+
* PRD 파일을 찾습니다
|
|
10
|
+
* @param userSpecified 사용자가 지정한 PRD 경로
|
|
11
|
+
* @param baseDir 검색 시작 디렉토리 (기본: 현재 디렉토리)
|
|
12
|
+
* @returns PRD 파일의 절대 경로 또는 null
|
|
13
|
+
*/
|
|
14
|
+
export declare function findPrd(userSpecified?: string, baseDir?: string): string | null;
|
|
15
|
+
/**
|
|
16
|
+
* PRD 파일을 읽습니다
|
|
17
|
+
* @param prdPath PRD 파일 경로
|
|
18
|
+
* @returns PRD 내용
|
|
19
|
+
*/
|
|
20
|
+
export declare function readPrd(prdPath: string): string;
|
|
21
|
+
/**
|
|
22
|
+
* PRD 파일이 존재하는지 확인
|
|
23
|
+
* @param baseDir 검색 디렉토리
|
|
24
|
+
* @returns PRD 존재 여부
|
|
25
|
+
*/
|
|
26
|
+
export declare function hasPrd(baseDir?: string): boolean;
|
|
27
|
+
/**
|
|
28
|
+
* PRD 파일 정보를 가져옵니다
|
|
29
|
+
* @param prdPath PRD 파일 경로
|
|
30
|
+
* @returns 파일 정보
|
|
31
|
+
*/
|
|
32
|
+
export declare function getPrdInfo(prdPath: string): {
|
|
33
|
+
path: string;
|
|
34
|
+
relativePath: string;
|
|
35
|
+
size: number;
|
|
36
|
+
sizeKB: string;
|
|
37
|
+
lastModified: Date;
|
|
38
|
+
};
|
|
39
|
+
//# sourceMappingURL=prd.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"prd.d.ts","sourceRoot":"","sources":["../../src/utils/prd.ts"],"names":[],"mappings":"AAAA;;GAEG;AAKH;;GAEG;AACH,eAAO,MAAM,cAAc,UAU1B,CAAC;AAEF;;;;;GAKG;AACH,wBAAgB,OAAO,CAAC,aAAa,CAAC,EAAE,MAAM,EAAE,OAAO,GAAE,MAAsB,GAAG,MAAM,GAAG,IAAI,CAoB9F;AAED;;;;GAIG;AACH,wBAAgB,OAAO,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CAE/C;AAED;;;;GAIG;AACH,wBAAgB,MAAM,CAAC,OAAO,GAAE,MAAsB,GAAG,OAAO,CAE/D;AAED;;;;GAIG;AACH,wBAAgB,UAAU,CAAC,OAAO,EAAE,MAAM,GAAG;IAC3C,IAAI,EAAE,MAAM,CAAC;IACb,YAAY,EAAE,MAAM,CAAC;IACrB,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,MAAM,CAAC;IACf,YAAY,EAAE,IAAI,CAAC;CACpB,CAWA"}
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* PRD (Product Requirements Document) 관리 유틸리티
|
|
3
|
+
*/
|
|
4
|
+
import * as fs from 'fs';
|
|
5
|
+
import * as path from 'path';
|
|
6
|
+
/**
|
|
7
|
+
* PRD 파일 검색 우선순위 목록
|
|
8
|
+
*/
|
|
9
|
+
export const PRD_CANDIDATES = [
|
|
10
|
+
'PRD.md',
|
|
11
|
+
'REQUIREMENTS.md',
|
|
12
|
+
'docs/prd.md',
|
|
13
|
+
'docs/PRD.md',
|
|
14
|
+
'docs/requirements.md',
|
|
15
|
+
'docs/REQUIREMENTS.md',
|
|
16
|
+
'.aiag/PRD.md',
|
|
17
|
+
'spec/PRD.md',
|
|
18
|
+
'spec/requirements.md',
|
|
19
|
+
];
|
|
20
|
+
/**
|
|
21
|
+
* PRD 파일을 찾습니다
|
|
22
|
+
* @param userSpecified 사용자가 지정한 PRD 경로
|
|
23
|
+
* @param baseDir 검색 시작 디렉토리 (기본: 현재 디렉토리)
|
|
24
|
+
* @returns PRD 파일의 절대 경로 또는 null
|
|
25
|
+
*/
|
|
26
|
+
export function findPrd(userSpecified, baseDir = process.cwd()) {
|
|
27
|
+
// 사용자가 지정한 경로 우선
|
|
28
|
+
if (userSpecified) {
|
|
29
|
+
const fullPath = path.resolve(baseDir, userSpecified);
|
|
30
|
+
if (fs.existsSync(fullPath)) {
|
|
31
|
+
return fullPath;
|
|
32
|
+
}
|
|
33
|
+
// 사용자가 지정했는데 없으면 null (에러 처리 위해)
|
|
34
|
+
return null;
|
|
35
|
+
}
|
|
36
|
+
// 자동 탐색
|
|
37
|
+
for (const candidate of PRD_CANDIDATES) {
|
|
38
|
+
const fullPath = path.join(baseDir, candidate);
|
|
39
|
+
if (fs.existsSync(fullPath)) {
|
|
40
|
+
return fullPath;
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
return null;
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* PRD 파일을 읽습니다
|
|
47
|
+
* @param prdPath PRD 파일 경로
|
|
48
|
+
* @returns PRD 내용
|
|
49
|
+
*/
|
|
50
|
+
export function readPrd(prdPath) {
|
|
51
|
+
return fs.readFileSync(prdPath, 'utf-8');
|
|
52
|
+
}
|
|
53
|
+
/**
|
|
54
|
+
* PRD 파일이 존재하는지 확인
|
|
55
|
+
* @param baseDir 검색 디렉토리
|
|
56
|
+
* @returns PRD 존재 여부
|
|
57
|
+
*/
|
|
58
|
+
export function hasPrd(baseDir = process.cwd()) {
|
|
59
|
+
return findPrd(undefined, baseDir) !== null;
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* PRD 파일 정보를 가져옵니다
|
|
63
|
+
* @param prdPath PRD 파일 경로
|
|
64
|
+
* @returns 파일 정보
|
|
65
|
+
*/
|
|
66
|
+
export function getPrdInfo(prdPath) {
|
|
67
|
+
const stats = fs.statSync(prdPath);
|
|
68
|
+
const baseDir = process.cwd();
|
|
69
|
+
return {
|
|
70
|
+
path: prdPath,
|
|
71
|
+
relativePath: path.relative(baseDir, prdPath),
|
|
72
|
+
size: stats.size,
|
|
73
|
+
sizeKB: (stats.size / 1024).toFixed(1),
|
|
74
|
+
lastModified: stats.mtime,
|
|
75
|
+
};
|
|
76
|
+
}
|
|
77
|
+
//# sourceMappingURL=prd.js.map
|