specthread 0.1.0 → 0.1.2

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 ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Chanha Park
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -5,11 +5,13 @@ Spec-Driven Development (SDD) 도구. 문서가 단일 진실 원천이고, 검
5
5
  ## 시작하기
6
6
 
7
7
  ```bash
8
- npm install -D specthread
9
- npx specthread init
10
- npx specthread check
8
+ npm install -g specthread
9
+ specthread init
10
+ specthread check
11
11
  ```
12
12
 
13
+ 프로젝트 로컬로 쓰려면 `npm install -D specthread` 후 `npx specthread`로 실행한다.
14
+
13
15
  `init`이 프로젝트에 SDD 체계를 세팅한다:
14
16
 
15
17
  ```
@@ -18,9 +20,9 @@ specthread/ ← 문서 규칙·설정·미확정 사항
18
20
  rules.md
19
21
  project.md
20
22
  pending.md
21
- docs/templates/ ← 문서 골격 (수정 가능, check 대상)
22
- spec.md
23
- plan.md
23
+ templates/ ← 문서 골격 (수정 가능, check 대상)
24
+ spec.md
25
+ plan.md
24
26
  AGENTS.md ← AI 도구 진입점
25
27
  CLAUDE.md ← Claude Code용 (@AGENTS.md)
26
28
  .claude/skills/ ← Claude Code 스킬
@@ -59,14 +61,14 @@ specthread/config.local.jsonc (개인)
59
61
 
60
62
  설정이 없으면 기본값으로 동작한다. init이 생성하는 `config.jsonc`에 모든 옵션이 주석으로 설명되어 있다.
61
63
 
62
- | 키 | 역할 |
63
- |---|---|
64
- | `path` | 스캔 대상 경로 (자유 KV) |
65
- | `features` | 기능 플래그 (`markers`, `emDash`, `references`) |
66
- | `markers` | 마커 종류·시점 라벨 |
67
- | `docTypes` | 경로별 템플릿·프론트매터 스키마 |
68
- | `skipCheck` | 검사 건너뛸 경로 |
69
- | `skipRefs` | 참조 절 생성 건너뛸 경로 |
64
+ | 키 | 역할 |
65
+ | ----------- | ----------------------------------------------- |
66
+ | `path` | 스캔 대상 경로 (자유 KV) |
67
+ | `features` | 기능 플래그 (`markers`, `emDash`, `references`) |
68
+ | `markers` | 마커 종류·시점 라벨 |
69
+ | `docTypes` | 경로별 템플릿·프론트매터 스키마 |
70
+ | `skipCheck` | 검사 건너뛸 경로 |
71
+ | `skipRefs` | 참조 절 생성 건너뛸 경로 |
70
72
 
71
73
  ## SDD 작업 흐름
72
74
 
@@ -112,20 +114,20 @@ AI는 작업 중에 `check`와 `gen`을 자동으로 호출한다. `AGENTS.md`
112
114
 
113
115
  `AGENTS.md`가 본체. 대부분의 AI 코딩 도구가 이 파일을 읽는다.
114
116
 
115
- | 도구 | 동작 |
116
- |------|------|
117
- | Claude Code | `CLAUDE.md`의 `@AGENTS.md`가 자동 확장 |
118
- | Cursor / Copilot / Codex / Gemini | `AGENTS.md`를 네이티브로 읽음 |
117
+ | 도구 | 동작 |
118
+ | --------------------------------- | -------------------------------------- |
119
+ | Claude Code | `CLAUDE.md`의 `@AGENTS.md`가 자동 확장 |
120
+ | Cursor / Copilot / Codex / Gemini | `AGENTS.md`를 네이티브로 읽음 |
119
121
 
120
122
  `--tools claude` (기본값)로 init하면 Claude Code 스킬이 함께 설치된다:
121
123
 
122
- | 스킬 | 역할 |
123
- |------|------|
124
- | `/check` | 문서 검사 실행 + 결과 해석 |
125
- | `/gen` | 참조 절·목차 생성 + 적용 안내 |
126
- | `/plan-open` | 작업 계획 문서 작성·검수·확정 |
127
- | `/plan-run` | 계획에 따라 실행·기록 |
128
- | `/plan-close` | 완료된 작업을 spec에 흡수 |
124
+ | 스킬 | 역할 |
125
+ | ------------- | ----------------------------- |
126
+ | `/check` | 문서 검사 실행 + 결과 해석 |
127
+ | `/gen` | 참조 절·목차 생성 + 적용 안내 |
128
+ | `/plan-open` | 작업 계획 문서 작성·검수·확정 |
129
+ | `/plan-run` | 계획에 따라 실행·기록 |
130
+ | `/plan-close` | 완료된 작업을 spec에 흡수 |
129
131
 
130
132
  스킬 없이 자연어로 같은 작업을 요청해도 된다. `AGENTS.md`가 AI에게 워크플로우를 알려주기 때문이다. 스킬은 자주 쓰는 흐름의 단축키다.
131
133
 
package/dist/bin/cli.js CHANGED
@@ -1,11 +1,22 @@
1
1
  #!/usr/bin/env node
2
2
  const [command, ...rest] = process.argv.slice(2);
3
- const usage = `specthread <command>
3
+ const usage = `specthread — Spec-Driven Development (SDD) 도구
4
+
5
+ 사용법: specthread <command> [options]
4
6
 
5
7
  commands:
6
- init [--tools claude,cursor] 프로젝트 초기화
7
- check 문서 검사
8
- gen [--write] 참조/목차 생성`;
8
+ init [--tools claude,cursor] 프로젝트에 SDD 체계 초기화
9
+ check 문서 정합성 검사 (28개 규칙)
10
+ gen [--write] 참조 절·목차·미확정 사항 요약 생성
11
+ help 이 도움말 표시
12
+
13
+ examples:
14
+ npx specthread init 새 프로젝트에 SDD 세팅
15
+ npx specthread check 문서 규칙 위반 검사
16
+ npx specthread gen 변경 대상 미리보기
17
+ npx specthread gen --write 실제 적용
18
+
19
+ https://github.com/dingPie/specthread`;
9
20
  const run = async () => {
10
21
  switch (command) {
11
22
  case "check":
@@ -17,9 +28,14 @@ const run = async () => {
17
28
  case "init":
18
29
  await (await import("../commands/init.js")).init(rest);
19
30
  break;
31
+ case "help":
32
+ case "--help":
33
+ case "-h":
34
+ console.log(usage);
35
+ break;
20
36
  default:
21
37
  console.log(usage);
22
- process.exit(command === undefined || command === "--help" ? 0 : 1);
38
+ process.exit(command === undefined ? 0 : 1);
23
39
  }
24
40
  };
25
41
  run();
@@ -88,13 +88,13 @@ export const init = (args) => {
88
88
  console.log(` specthread/${file} 이미 존재 - 건너뜀`);
89
89
  }
90
90
  const templateFiles = ["spec.md", "plan.md"];
91
- const templatesDir = join(cwd, "docs", "templates");
91
+ const templatesDir = join(stDir, "templates");
92
92
  for (const file of templateFiles) {
93
93
  const created = copyIfMissing(join(scaffold, "templates", file), join(templatesDir, file));
94
94
  if (created)
95
- console.log(` docs/templates/${file} 생성`);
95
+ console.log(` specthread/templates/${file} 생성`);
96
96
  else
97
- console.log(` docs/templates/${file} 이미 존재 - 건너뜀`);
97
+ console.log(` specthread/templates/${file} 이미 존재 - 건너뜀`);
98
98
  }
99
99
  ensureAgentsMd(cwd, scaffold);
100
100
  if (tools.has("claude")) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "specthread",
3
- "version": "0.1.0",
3
+ "version": "0.1.2",
4
4
  "description": "Spec-Driven Development (SDD) template. Docs are the single source of truth; code implements docs.",
5
5
  "type": "module",
6
6
  "bin": {
@@ -11,12 +11,19 @@
11
11
  "scaffold/"
12
12
  ],
13
13
  "license": "MIT",
14
+ "repository": {
15
+ "type": "git",
16
+ "url": "https://github.com/dingPie/specthread.git"
17
+ },
14
18
  "engines": {
15
19
  "node": ">=18.0.0"
16
20
  },
17
21
  "scripts": {
18
22
  "build": "tsc -p tsconfig.build.json",
19
23
  "prepublishOnly": "npm run build",
24
+ "release:patch": "npm version patch && npm publish && git push --tags",
25
+ "release:minor": "npm version minor && npm publish && git push --tags",
26
+ "release:major": "npm version major && npm publish && git push --tags",
20
27
  "docs:check": "node tools/docs/bin/check.ts",
21
28
  "docs:generate": "node tools/docs/bin/generate.ts",
22
29
  "docs:test": "node --test \"tools/docs/__tests__/*.test.ts\"",
@@ -38,7 +38,7 @@
38
38
  // "docTypes": {
39
39
  // "spec": {
40
40
  // "path": "docs/spec/",
41
- // "template": "docs/templates/spec.md",
41
+ // "template": "specthread/templates/spec.md",
42
42
  // "frontmatter": { "required": ["title"], "optional": ["status"] }
43
43
  // }
44
44
  // }
@@ -56,7 +56,7 @@
56
56
 
57
57
  // ── 참조 절 생성 제외 (기본값: []) ──────────────────────────────
58
58
  // 이 경로 prefix 의 문서에는 참조 절을 생성하지 않는다.
59
- // "skipRefs": ["docs/templates/"]
59
+ // "skipRefs": ["specthread/templates/"]
60
60
 
61
61
  // ── 로케일 (기본값: "ko") ───────────────────────────────────────
62
62
  // 현재 한국어 고정. 검사 메시지, 꼬리 절 이름, 시점 정규식 등에 영향.