@warnyin/agents 0.6.0 → 0.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/CHANGELOG.md +33 -0
- package/package.json +14 -9
- package/{bin → src/bin}/cli.mjs +3 -0
- package/CLAUDE.md +0 -40
- /package/{.claude → src/.claude}/agents/warnyin-infra.md +0 -0
- /package/{.claude → src/.claude}/agents/warnyin-qa.md +0 -0
- /package/{.claude → src/.claude}/agents/warnyin-sa.md +0 -0
- /package/{.claude → src/.claude}/agents/warnyin-security.md +0 -0
- /package/{.claude → src/.claude}/agents/warnyin-tech-lead.md +0 -0
- /package/{.claude → src/.claude}/commands/warnyin/build.md +0 -0
- /package/{.claude → src/.claude}/commands/warnyin/design.md +0 -0
- /package/{.claude → src/.claude}/commands/warnyin/discovery.md +0 -0
- /package/{.claude → src/.claude}/commands/warnyin/explore.md +0 -0
- /package/{.claude → src/.claude}/commands/warnyin/init.md +0 -0
- /package/{.claude → src/.claude}/commands/warnyin/install-skill.md +0 -0
- /package/{.claude → src/.claude}/commands/warnyin/next.md +0 -0
- /package/{.claude → src/.claude}/commands/warnyin/ship.md +0 -0
- /package/{.claude → src/.claude}/commands/warnyin/update-codemaps.md +0 -0
- /package/{.claude → src/.claude}/commands/warnyin/verify.md +0 -0
- /package/{.warnyin → src/.warnyin}/installer/templates/CLAUDE.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/docs/codemap/index.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/docs/features/[feature-name]/business.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/docs/features/[feature-name]/feature.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/docs/infra.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/docs/project.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/docs/rule.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/docs/techstack/[component]/about.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/docs/techstack/[component]/rule.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/docs/techstack/[component]/standard.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/docs/techstack/[component]/structure.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/docs/techstack/[component]/test.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/docs/troubleshooting.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/stages/[topic]/build.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/stages/[topic]/business.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/stages/[topic]/design.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/stages/[topic]/discovery.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/stages/[topic]/proposal.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/stages/[topic]/research.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/stages/[topic]/ship.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/stages/[topic]/tasks/[task-name]/issue.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/stages/[topic]/tasks/[task-name]/rule.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/stages/[topic]/tasks/[task-name]/spec.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/stages/[topic]/tasks/[task-name]/standard.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/stages/[topic]/tasks/[task-name]/task.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/stages/[topic]/test.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/stages/[topic]/troubleshooting.md +0 -0
- /package/{.warnyin → src/.warnyin}/template/stages/[topic]/verify.md +0 -0
- /package/{.warnyin → src/.warnyin}/workflow/README.md +0 -0
- /package/{.warnyin → src/.warnyin}/workflow/codemap.md +0 -0
- /package/{.warnyin → src/.warnyin}/workflow/explore.md +0 -0
- /package/{.warnyin → src/.warnyin}/workflow/init.md +0 -0
- /package/{.warnyin → src/.warnyin}/workflow/next.md +0 -0
- /package/{.warnyin → src/.warnyin}/workflow/roles/README.md +0 -0
- /package/{.warnyin → src/.warnyin}/workflow/roles/ba.md +0 -0
- /package/{.warnyin → src/.warnyin}/workflow/roles/developer.md +0 -0
- /package/{.warnyin → src/.warnyin}/workflow/roles/infra.md +0 -0
- /package/{.warnyin → src/.warnyin}/workflow/roles/po.md +0 -0
- /package/{.warnyin → src/.warnyin}/workflow/roles/qa.md +0 -0
- /package/{.warnyin → src/.warnyin}/workflow/roles/sa.md +0 -0
- /package/{.warnyin → src/.warnyin}/workflow/roles/security.md +0 -0
- /package/{.warnyin → src/.warnyin}/workflow/roles/tech-lead.md +0 -0
- /package/{.warnyin → src/.warnyin}/workflow/scripts/build-wave.mjs +0 -0
- /package/{.warnyin → src/.warnyin}/workflow/stages/build.md +0 -0
- /package/{.warnyin → src/.warnyin}/workflow/stages/design.md +0 -0
- /package/{.warnyin → src/.warnyin}/workflow/stages/discovery.md +0 -0
- /package/{.warnyin → src/.warnyin}/workflow/stages/ship.md +0 -0
- /package/{.warnyin → src/.warnyin}/workflow/stages/verify.md +0 -0
- /package/{AGENTS.md → src/AGENTS.md} +0 -0
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
ทุกการเปลี่ยนแปลงที่สำคัญของโปรเจกต์นี้ถูกบันทึกในไฟล์นี้
|
|
4
|
+
|
|
5
|
+
รูปแบบอ้างอิง [Keep a Changelog](https://keepachangelog.com/en/1.1.0/)
|
|
6
|
+
และโปรเจกต์ยึด [Semantic Versioning](https://semver.org/spec/v2.0.0.html)
|
|
7
|
+
|
|
8
|
+
## [Unreleased]
|
|
9
|
+
|
|
10
|
+
## [0.7.0] - 2026-06-07
|
|
11
|
+
|
|
12
|
+
### Added
|
|
13
|
+
- **Bootstrap / self-hosting (2-layer):** แยก source ของ warnyin ทั้งหมดเข้า `src/` (committed/publish layer); repo install release เสถียรไว้ root เป็น dogfood (`.warnyin/`/`.claude/`/`CLAUDE.md`/`AGENTS.md` — gitignored) เพื่อพัฒนา `src/` โดย workflow ที่ใช้ทำงานยังเสถียร
|
|
14
|
+
- `npm run setup:dogfood` — คืน dogfood env ที่ root จาก release (`npx @latest` + fallback `npm pack`→extract→node สำหรับ Windows), append pointer → `CONTRIBUTING.md` แบบ idempotent
|
|
15
|
+
- `npm run setup:sandbox` — install v-next จาก `src/` ลง temp dir (`os.tmpdir()`) เพื่อทดสอบ version skew โดยไม่แตะ dogfood ที่ root
|
|
16
|
+
- `CONTRIBUTING.md` — dev-instructions ของ repo (แยกจาก root `CLAUDE.md` เดิม)
|
|
17
|
+
- pass-count gate (`src/scripts/check-test-count.mjs`) — anti-false-green: fail ถ้า `fail≠0` / `pass<9` / `pass≠tests`
|
|
18
|
+
- Automated installer test suite (`node:test` black-box — spawn `src/bin/cli.mjs` จริงใน temp dir แล้ว assert side-effect) + unit test `checkFiles` รันด้วย `npm test`
|
|
19
|
+
- GitHub Actions CI (`.github/workflows/ci.yml`) — matrix node 20/22/24 + job `pack-verify`
|
|
20
|
+
- npm-pack verify (`src/scripts/verify-pack.mjs`) — testable `checkFiles(files)→errors[]`: allowlist granular + denylist (tooling/`docs/`/dogfood ที่ root) + tripwire (`settings.local.json`/`*.tgz`/`.env*`); assert `src/.warnyin/workflow/` + `src/.claude/commands/warnyin/` ติด tarball
|
|
21
|
+
|
|
22
|
+
### Changed
|
|
23
|
+
- **bin path** `bin/cli.mjs` → `src/bin/cli.mjs` (restructure source เข้า `src/`) — `pkgRoot` resolve เป็น `src/` อัตโนมัติ, payload คงเดิม
|
|
24
|
+
- `package.json files` เป็น allowlist granular — nested dotfolder ระบุชัด (`src/.warnyin`, `src/.claude/commands`, `src/.claude/agents`); ตัด `src/tests`/`src/scripts` (dev-only)
|
|
25
|
+
- test/scripts ย้ายไป `src/tests/` + `src/scripts/`; `npm test` = `node --test` bare (auto-discover, portable node 20/22/24)
|
|
26
|
+
- `engines.node` `>=18` → `>=20` (node 18 EOL)
|
|
27
|
+
- `.gitignore` เพิ่ม dogfood layer (root-anchored ทุกบรรทัด — กัน match `src/.claude`/`src/.warnyin`)
|
|
28
|
+
|
|
29
|
+
### Removed
|
|
30
|
+
- รองรับ node 18 (drop ตาม EOL)
|
|
31
|
+
|
|
32
|
+
[Unreleased]: https://github.com/warnyin/warnyin-agents/compare/v0.7.0...HEAD
|
|
33
|
+
[0.7.0]: https://github.com/warnyin/warnyin-agents/compare/v0.6.0...v0.7.0
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@warnyin/agents",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.7.0",
|
|
4
4
|
"description": "Warnyin Standard Workflow installer — 5-stage ways of work (Discovery/DESIGN/BUILD/VERIFY/SHIP) สำหรับทุกโปรเจกต์",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -8,18 +8,23 @@
|
|
|
8
8
|
"access": "public"
|
|
9
9
|
},
|
|
10
10
|
"bin": {
|
|
11
|
-
"warnyin-agents": "bin/cli.mjs"
|
|
11
|
+
"warnyin-agents": "src/bin/cli.mjs"
|
|
12
12
|
},
|
|
13
13
|
"scripts": {
|
|
14
|
-
"test": "node --test"
|
|
14
|
+
"test": "node --test",
|
|
15
|
+
"verify:pack": "node src/scripts/verify-pack.mjs",
|
|
16
|
+
"setup:dogfood": "node src/scripts/setup-dogfood.mjs",
|
|
17
|
+
"setup:sandbox": "node src/scripts/setup-sandbox.mjs"
|
|
15
18
|
},
|
|
16
19
|
"files": [
|
|
17
|
-
"bin",
|
|
18
|
-
"
|
|
19
|
-
"
|
|
20
|
-
"
|
|
21
|
-
"
|
|
22
|
-
"
|
|
20
|
+
"src/bin",
|
|
21
|
+
"src/.warnyin",
|
|
22
|
+
"src/.claude/commands",
|
|
23
|
+
"src/.claude/agents",
|
|
24
|
+
"src/AGENTS.md",
|
|
25
|
+
"README.md",
|
|
26
|
+
"CHANGELOG.md",
|
|
27
|
+
"LICENSE"
|
|
23
28
|
],
|
|
24
29
|
"engines": {
|
|
25
30
|
"node": ">=20"
|
package/{bin → src/bin}/cli.mjs
RENAMED
|
@@ -32,6 +32,9 @@ if (args.has('--help') || args.has('-h')) {
|
|
|
32
32
|
process.exit(0)
|
|
33
33
|
}
|
|
34
34
|
|
|
35
|
+
// guard กัน self-install — เก็บไว้แบบ defensive (zero-cost)
|
|
36
|
+
// หลังย้าย source เข้า src/ → pkgRoot = src/ (sibling ของ bin/) จึงแทบไม่มีทาง === target (repo root / temp sandbox)
|
|
37
|
+
// → guard นี้เป็น no-op โดยตั้งใจในเคสปกติ/sandbox; ยังคงดักได้เฉพาะ edge case ที่ install ลงโฟลเดอร์ที่เป็น src/ เอง
|
|
35
38
|
if (path.resolve(pkgRoot) === path.resolve(target)) {
|
|
36
39
|
console.error('✖ กำลังรันอยู่ใน repo ของ warnyin-agents เอง — ให้ cd ไปที่โปรเจกต์ปลายทางก่อน')
|
|
37
40
|
process.exit(1)
|
package/CLAUDE.md
DELETED
|
@@ -1,40 +0,0 @@
|
|
|
1
|
-
# CLAUDE.md
|
|
2
|
-
|
|
3
|
-
repo มาตรฐานกลางของ **ways of work** สำหรับทุกโปรเจกต์ เดินงานผ่าน 5 stage:
|
|
4
|
-
`Discovery (optional) ▶ DESIGN ▶ BUILD ▶ VERIFY ▶ SHIP`
|
|
5
|
-
|
|
6
|
-
## กฎหลัก
|
|
7
|
-
- แก่นของแต่ละ stage เป็น single source of truth ที่ `.warnyin/workflow/stages/` — **ทำตาม playbook นั้นเสมอ** ก่อนเริ่มงานใน stage
|
|
8
|
-
- อย่า duplicate logic ของ workflow ลงที่อื่น ถ้าต้องแก้พฤติกรรมให้แก้ที่ `.warnyin/workflow/stages/`
|
|
9
|
-
- output ของงานจริงเก็บใน `docs/stages/<slug>/` (copy จาก template `.warnyin/template/stages/[topic]/`)
|
|
10
|
-
- ความรู้ถาวรระดับโปรเจกต์อยู่ใน `docs/` — เริ่มอ่าน `docs/project.md` เสมอใน Discovery
|
|
11
|
-
- role card กลางอยู่ที่ `.warnyin/workflow/roles/` (BA/PO/SA/Tech Lead/Developer/QA/Security/Infra) — stage ไหนใช้ role ไหนดูใน playbook; reviewer subagent ของ Claude Code อยู่ที่ `.claude/agents/warnyin-*`
|
|
12
|
-
|
|
13
|
-
## Slash commands (namespace `warnyin:`)
|
|
14
|
-
- `/warnyin:init` → วิเคราะห์โปรเจกต์ + เติม `docs/` ครั้งแรกหลังติดตั้ง (`.claude/commands/warnyin/init.md` → `.warnyin/workflow/init.md`)
|
|
15
|
-
- `/warnyin:install-skill [role]` → ติดตั้ง skill เสริมประจำ role (รายการอยู่ที่ตารางใน `.warnyin/workflow/roles/README.md`)
|
|
16
|
-
- `/warnyin:update-codemaps` → สแกนโครงสร้าง + สร้าง/อัปเดต codemap แบบ token-lean ใน `docs/codemap/` (`.warnyin/workflow/codemap.md`)
|
|
17
|
-
- `/warnyin:explore [คำถาม]` → สำรวจ/ตอบคำถามแบบ read-only — ไม่สร้าง artifact ใดๆ จบที่คำตอบในแชท (`.warnyin/workflow/explore.md`)
|
|
18
|
-
- `/warnyin:next [slug]` → เช็คงานค้างทุก topic + แนะนำ command ถัดไป แบบ read-only (`.warnyin/workflow/next.md`)
|
|
19
|
-
- `/warnyin:discovery [topic]` → Discovery stage (`.claude/commands/warnyin/discovery.md` → `.warnyin/workflow/stages/discovery.md`)
|
|
20
|
-
- `/warnyin:design [slug] [change]` → DESIGN stage (`.claude/commands/warnyin/design.md` → `.warnyin/workflow/stages/design.md`)
|
|
21
|
-
- `/warnyin:build [slug]` → BUILD stage — fan-out sub-agent ตาม dependency (`.warnyin/workflow/stages/build.md` + `.warnyin/workflow/scripts/build-wave.mjs`)
|
|
22
|
-
- `/warnyin:verify [slug]` → VERIFY stage — strategy tester เทส local env + UXUI แก้จนผ่าน (`.warnyin/workflow/stages/verify.md`)
|
|
23
|
-
- `/warnyin:ship [slug]` → SHIP stage — ส่งมอบ: promote ความรู้ขึ้น `docs/` + archive topic (`.warnyin/workflow/stages/ship.md`)
|
|
24
|
-
|
|
25
|
-
## การติดตั้งไปโปรเจกต์อื่น (npx installer)
|
|
26
|
-
- `npx @warnyin/agents` (หรือสำรอง `npx github:warnyin/warnyin-agents`) → copy โครงทั้งหมดลงโปรเจกต์ปลายทาง (ข้ามไฟล์ที่มีอยู่, CLAUDE.md/AGENTS.md ที่มีอยู่จะต่อท้ายเป็น section)
|
|
27
|
-
- `--update` → เขียนทับเฉพาะ core (`.warnyin/workflow/`, `.claude/commands/warnyin/`, template ใน `.warnyin/template/`) ไม่แตะ `docs/`/งานจริง
|
|
28
|
-
- ตัว installer: `bin/cli.mjs` + template CLAUDE.md ของโปรเจกต์ปลายทางที่ `.warnyin/installer/templates/CLAUDE.md` (แก้ commands list ที่ไหน ให้แก้ template นี้ด้วย; โฟลเดอร์นี้ไม่ถูก copy ไป target)
|
|
29
|
-
- หลังติดตั้ง → รัน `/warnyin:init` เพื่อเติม `docs/`
|
|
30
|
-
|
|
31
|
-
## รองรับหลาย AI
|
|
32
|
-
repo นี้ tool-agnostic: Claude Code อ่าน `.claude/` + ไฟล์นี้, ส่วน Codex/Antigravity อ่าน `AGENTS.md`
|
|
33
|
-
ทุกเครื่องชี้กลับมาที่ playbook กลางชุดเดียวกันใน `.warnyin/workflow/stages/` — ดูภาพรวมที่ `.warnyin/workflow/README.md`
|
|
34
|
-
|
|
35
|
-
## สถานะการสร้าง workflow (อัปเดต 2026-06-04)
|
|
36
|
-
ครบทั้ง 5 stage: Discovery ✅ · DESIGN ✅ · BUILD ✅ · VERIFY ✅ · SHIP ✅
|
|
37
|
-
(playbook + command + template + build-wave.mjs ครบทุก stage)
|
|
38
|
-
|
|
39
|
-
แพทเทิร์นการเติม/แก้ stage: playbook `.warnyin/workflow/stages/<stage>.md` + command `.claude/commands/warnyin/<stage>.md` + อัปเดตตาราง stage ใน `AGENTS.md`/`CLAUDE.md`/`.warnyin/workflow/README.md` + output template ใน `.warnyin/template/stages/[topic]/`
|
|
40
|
-
**สำคัญ: การเปลี่ยนพฤติกรรม stage ใดๆ ให้ user เป็นคนอธิบาย/ยืนยันก่อน อย่าเดาเอง**
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|