dw-kit 1.1.0 → 1.2.1

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 CHANGED
@@ -1,119 +1,127 @@
1
- # dw-kit
2
-
3
- > An AI development workflow toolkit for teams using agentic IDEs (Claude Code, Cursor) — from idea to review-ready commits.
4
-
5
- **v1.0** · `npm install -g dw-kit` · [Docs](docs/README.md) · [Get started](docs/get-started.md) · [Cheatsheet](docs/cheatsheet.md)
6
-
7
- ---
8
-
9
- ## What is dw-kit?
10
-
11
- dw-kit helps your team run AI-assisted development with a **repeatable workflow** and clear checkpoints:
12
-
13
- ```
14
- Initialize → Understand → Plan → Execute (TDD) → Verify → Close
15
- ```
16
-
17
- <img src="docs/workflow-diagram.svg" alt="dw-kit workflow diagram" />
18
-
19
- ## Workflow overview
20
-
21
- `dw` runs a 6-phase process (all phases for `standard` and `thorough`):
22
-
23
- Initialize → Understand → Plan (stops for approval) → Execute (TDD; 1 commit per subtask) → Verify (quality gates + review sign-off) → Close (handoff + archive when done).
24
-
25
- ### 6 phases (full workflow)
26
- - **Initialize**: clarify task scope and set up the workspace + task docs.
27
- - **Understand**: survey the codebase, dependencies, patterns, and test coverage (no implementation).
28
- - **Plan**: design the solution and subtasks; **pause for your approval**.
29
- - **Execute**: implement using **TDD**; each subtask produces a commit.
30
- - **Verify**: run quality gates + review sign-off to ensure correctness and safety.
31
- - **Close**: handoff notes, finalize progress, and archive when done.
32
-
33
- It’s designed for collaboration (Dev / Tech Lead / QA / PM) and keeps work auditable via lightweight task docs.
34
-
35
- ---
36
-
37
- ## Install
38
-
39
- ```bash
40
- npm install -g dw-kit
41
- ```
42
-
43
- ---
44
-
45
- ## Quick start
46
-
47
- Setup dw in project directory:
48
-
49
- ```bash
50
- dw init
51
- ```
52
-
53
- Then in **Claude Code CLI**, run the full workflow:
54
-
55
- ```
56
- /dw-flow your-task-or-anythings
57
- ```
58
-
59
- ---
60
-
61
- Discover other skills:
62
-
63
- ```
64
- /dw-prompt
65
- /dw-thinking
66
- ...
67
-
68
- ```
69
-
70
- ---
71
-
72
- ## CLI commands
73
-
74
- ```bash
75
- dw init # setup wizard / presets
76
- dw validate # validate .dw/config/dw.config.yml
77
- dw doctor # installation health check
78
- dw upgrade # update toolkit files (override-aware)
79
- dw upgrade --check # check for updates only
80
- dw upgrade --dry-run # preview changes
81
- dw prompt # build a well-structured task prompt (autocomplete + wizard)
82
- dw prompt --text "..." # non-interactive: structure a description directly
83
- dw claude-vn-fix # patch Claude CLI to fix Vietnamese IME (backup/restore)
84
- ```
85
-
86
- `dw claude-vn-fix` patches the local Claude CLI bundle to fix Vietnamese IME input (DEL char `\x7f` issue). Includes auto-backup and rollback.
87
-
88
- ---
89
-
90
- ## Depth system
91
-
92
- Pick a default depth for your project, then override per task when risk increases.
93
-
94
- | Depth | Best for | Workflow |
95
- |-------|----------|----------|
96
- | `quick` | Solo dev, hotfix, familiar code | Understand → Execute → Close |
97
- | `standard` | Small teams, new features | Full 6 phases |
98
- | `thorough` | Risky changes (API/DB/security) | Full workflow + arch-review + test-plan |
99
-
100
- Configured in `.dw/config/dw.config.yml`:
101
-
102
- ```yaml
103
- workflow:
104
- default_depth: "standard"
105
- ```
106
-
107
- ---
108
-
109
- ## What gets added to your repo?
110
-
111
- ```
112
- .dw/ # methodology, config, adapters, task docs
113
- .claude/ # Claude Code: skills, hooks, agents, rules
114
- CLAUDE.md # project context for the agent
115
- ```
116
-
117
- ---
118
-
119
- Maintainer: [huygdv](mailto:huygdv19@gmail.com)
1
+ # dw-kit
2
+
3
+ > An AI development workflow toolkit for teams using agentic IDEs (Claude Code, Cursor) — from idea to review-ready commits.
4
+
5
+ **v1.2** · `npm install -g dw-kit` · [Docs](docs/README.md) · [Get started](docs/get-started.md) · [Cheatsheet](docs/cheatsheet.md) · [Changelog](CHANGELOG.md#v120--2026-04-09)
6
+
7
+ ---
8
+
9
+ ## What is dw-kit?
10
+
11
+ dw-kit helps your team run AI-assisted development with a **repeatable workflow** and clear checkpoints:
12
+
13
+ ```
14
+ Initialize → Understand → Plan → Execute (TDD) → Verify → Close
15
+ ```
16
+
17
+ <img src="docs/workflow-diagram.svg" alt="dw-kit workflow diagram" />
18
+
19
+ ## Workflow overview
20
+
21
+ `dw` runs a 6-phase process (all phases for `standard` and `thorough`):
22
+
23
+ Initialize → Understand → Plan (stops for approval) → Execute (TDD; 1 commit per subtask) → Verify (quality gates + review sign-off) → Close (handoff + archive when done).
24
+
25
+ ### 6 phases (full workflow)
26
+ - **Initialize**: clarify task scope and set up the workspace + task docs.
27
+ - **Understand**: survey the codebase, dependencies, patterns, and test coverage (no implementation).
28
+ - **Plan**: design the solution and subtasks; **pause for your approval**.
29
+ - **Execute**: implement using **TDD**; each subtask produces a commit.
30
+ - **Verify**: run quality gates + review sign-off to ensure correctness and safety.
31
+ - **Close**: handoff notes, finalize progress, and archive when done.
32
+
33
+ It’s designed for collaboration (Dev / Tech Lead / QA / PM) and keeps work auditable via lightweight task docs.
34
+
35
+ ---
36
+
37
+ ## Release notes
38
+
39
+ - v1.2.0 notes: [`CHANGELOG.md#v120--2026-04-09`](CHANGELOG.md#v120--2026-04-09)
40
+ - Full changelog: `CHANGELOG.md`
41
+ - Latest release notes: [GitHub Releases](https://github.com/dv-workflow/dv-workflow/releases)
42
+
43
+ ---
44
+
45
+ ## Install
46
+
47
+ ```bash
48
+ npm install -g dw-kit
49
+ ```
50
+
51
+ ---
52
+
53
+ ## Quick start
54
+
55
+ Setup dw in project directory:
56
+
57
+ ```bash
58
+ dw init
59
+ ```
60
+
61
+ Then in **Claude Code CLI**, run the full workflow:
62
+
63
+ ```
64
+ /dw-flow your-task-or-anythings
65
+ ```
66
+
67
+ ---
68
+
69
+ Discover other skills:
70
+
71
+ ```
72
+ /dw-prompt
73
+ /dw-thinking
74
+ ...
75
+
76
+ ```
77
+
78
+ ---
79
+
80
+ ## CLI commands
81
+
82
+ ```bash
83
+ dw init # setup wizard / presets
84
+ dw validate # validate .dw/config/dw.config.yml
85
+ dw doctor # installation health check
86
+ dw upgrade # update toolkit files (override-aware)
87
+ dw upgrade --check # check for updates only
88
+ dw upgrade --dry-run # preview changes
89
+ dw prompt # build a well-structured task prompt (autocomplete + wizard)
90
+ dw prompt --text "..." # non-interactive: structure a description directly
91
+ dw claude-vn-fix # patch Claude CLI to fix Vietnamese IME (backup/restore)
92
+ ```
93
+
94
+ `dw claude-vn-fix` patches the local Claude CLI bundle to fix Vietnamese IME input (DEL char `\x7f` issue). Includes auto-backup and rollback.
95
+
96
+ ---
97
+
98
+ ## Depth system
99
+
100
+ Pick a default depth for your project, then override per task when risk increases.
101
+
102
+ | Depth | Best for | Workflow |
103
+ |-------|----------|----------|
104
+ | `quick` | Solo dev, hotfix, familiar code | Understand → Execute → Close |
105
+ | `standard` | Small teams, new features | Full 6 phases |
106
+ | `thorough` | Risky changes (API/DB/security) | Full workflow + arch-review + test-plan |
107
+
108
+ Configured in `.dw/config/dw.config.yml`:
109
+
110
+ ```yaml
111
+ workflow:
112
+ default_depth: "standard"
113
+ ```
114
+
115
+ ---
116
+
117
+ ## What gets added to your repo?
118
+
119
+ ```
120
+ .dw/ # methodology, config, adapters, task docs
121
+ .claude/ # Claude Code: skills, hooks, agents, rules
122
+ CLAUDE.md # project context for the agent
123
+ ```
124
+
125
+ ---
126
+
127
+ Maintainer: [huygdv](mailto:huygdv19@gmail.com)
package/package.json CHANGED
@@ -1,57 +1,84 @@
1
- {
2
- "name": "dw-kit",
3
- "version": "1.1.0",
4
- "description": "AI development workflow toolkit — structured, quality-assured, team-ready. From requirements to dashboard.",
5
- "type": "module",
6
- "bin": {
7
- "dw": "bin/dw.mjs"
8
- },
9
- "files": [
10
- "bin/",
11
- "src/",
12
- ".dw/core/",
13
- ".dw/config/",
14
- ".dw/adapters/",
15
- "scripts/",
16
- ".claude/agents/",
17
- ".claude/hooks/",
18
- ".claude/rules/",
19
- ".claude/skills/",
20
- ".claude/templates/",
21
- ".claude/settings.json",
22
- "CLAUDE.md"
23
- ],
24
- "engines": {
25
- "node": ">=18"
26
- },
27
- "scripts": {
28
- "test": "node src/smoke-test.mjs",
29
- "link": "npm link",
30
- "test:e2e-local": "bash scripts/e2e-local-check.sh"
31
- },
32
- "keywords": [
33
- "ai",
34
- "workflow",
35
- "claude",
36
- "cursor",
37
- "development",
38
- "toolkit",
39
- "tdd",
40
- "code-review",
41
- "agent"
42
- ],
43
- "author": "huygdv <huygdv19@gmail.com>",
44
- "license": "MIT",
45
- "repository": {
46
- "type": "git",
47
- "url": "git+https://github.com/dv-workflow/dv-workflow.git"
48
- },
49
- "homepage": "https://github.com/dv-workflow/dv-workflow#readme",
50
- "dependencies": {
51
- "ajv": "^8.18.0",
52
- "chalk": "^5.6.2",
53
- "commander": "^14.0.3",
54
- "enquirer": "^2.4.1",
55
- "js-yaml": "^4.1.1"
56
- }
57
- }
1
+ {
2
+ "name": "dw-kit",
3
+ "version": "1.2.1",
4
+ "description": "AI development workflow toolkit — structured, quality-assured, team-ready. From requirements to dashboard.",
5
+ "type": "module",
6
+ "bin": {
7
+ "dw": "bin/dw.mjs"
8
+ },
9
+ "files": [
10
+ "bin/",
11
+ "src/cli.mjs",
12
+ "src/commands/",
13
+ "src/lib/",
14
+ ".dw/core/",
15
+ ".dw/config/",
16
+ ".dw/adapters/",
17
+ ".claude/agents/",
18
+ ".claude/hooks/",
19
+ ".claude/rules/",
20
+ ".claude/skills/dw-arch-review/",
21
+ ".claude/skills/dw-archive/",
22
+ ".claude/skills/dw-commit/",
23
+ ".claude/skills/dw-config-init/",
24
+ ".claude/skills/dw-config-validate/",
25
+ ".claude/skills/dw-dashboard/",
26
+ ".claude/skills/dw-debug/",
27
+ ".claude/skills/dw-docs-update/",
28
+ ".claude/skills/dw-estimate/",
29
+ ".claude/skills/dw-execute/",
30
+ ".claude/skills/dw-flow/",
31
+ ".claude/skills/dw-handoff/",
32
+ ".claude/skills/dw-kit-report/",
33
+ ".claude/skills/dw-log-work/",
34
+ ".claude/skills/dw-onboard/",
35
+ ".claude/skills/dw-plan/",
36
+ ".claude/skills/dw-prompt/",
37
+ ".claude/skills/dw-requirements/",
38
+ ".claude/skills/dw-research/",
39
+ ".claude/skills/dw-retroactive/",
40
+ ".claude/skills/dw-review/",
41
+ ".claude/skills/dw-rollback/",
42
+ ".claude/skills/dw-sprint-review/",
43
+ ".claude/skills/dw-task-init/",
44
+ ".claude/skills/dw-test-plan/",
45
+ ".claude/skills/dw-thinking/",
46
+ ".claude/skills/dw-upgrade/",
47
+ ".claude/templates/",
48
+ ".claude/settings.json",
49
+ "CLAUDE.md"
50
+ ],
51
+ "engines": {
52
+ "node": ">=18"
53
+ },
54
+ "scripts": {
55
+ "test": "node src/smoke-test.mjs",
56
+ "link": "npm link",
57
+ "test:e2e-local": "bash scripts/e2e-local-check.sh"
58
+ },
59
+ "keywords": [
60
+ "ai",
61
+ "workflow",
62
+ "claude",
63
+ "cursor",
64
+ "development",
65
+ "toolkit",
66
+ "tdd",
67
+ "code-review",
68
+ "agent"
69
+ ],
70
+ "author": "huygdv <huygdv19@gmail.com>",
71
+ "license": "MIT",
72
+ "repository": {
73
+ "type": "git",
74
+ "url": "git+https://github.com/dv-workflow/dv-workflow.git"
75
+ },
76
+ "homepage": "https://github.com/dv-workflow/dv-workflow#readme",
77
+ "dependencies": {
78
+ "ajv": "^8.18.0",
79
+ "chalk": "^5.6.2",
80
+ "commander": "^14.0.3",
81
+ "enquirer": "^2.4.1",
82
+ "js-yaml": "^4.1.1"
83
+ }
84
+ }
package/src/cli.mjs CHANGED
@@ -1,92 +1,100 @@
1
- import { Command } from 'commander';
2
- import { createRequire } from 'node:module';
3
- import { fileURLToPath } from 'node:url';
4
- import { dirname, join } from 'node:path';
5
- import chalk from 'chalk';
6
- import { getUpdateNotice, scheduleUpdateCheck } from './lib/update-checker.mjs';
7
-
8
- const __filename = fileURLToPath(import.meta.url);
9
- const __dirname = dirname(__filename);
10
- const require = createRequire(import.meta.url);
11
- const pkg = require(join(__dirname, '..', 'package.json'));
12
-
13
- export function run(argv) {
14
- // Show cached update notice (non-blocking), then schedule fresh check in background
15
- const latestVersion = getUpdateNotice(pkg.version);
16
- scheduleUpdateCheck(pkg.version);
17
-
18
- const program = new Command();
19
-
20
- program
21
- .name('dw')
22
- .description('dw-kit — AI development workflow toolkit')
23
- .version(pkg.version, '-v, --version');
24
-
25
- program
26
- .command('init')
27
- .description('Setup dw-kit in current project (interactive wizard)')
28
- .option('-p, --preset <name>', 'Use preset: solo-quick | small-team | enterprise')
29
- .option('-a, --adapter <platform>', 'Target platform: claude-cli | cursor | generic', 'claude-cli')
30
- .option('-s, --silent', 'Non-interactive mode (reads DW_NAME, DW_DEPTH, DW_ROLES, DW_LANG env vars)')
31
- .action(async (opts) => {
32
- const { initCommand } = await import('./commands/init.mjs');
33
- await initCommand(opts);
34
- });
35
-
36
- program
37
- .command('upgrade')
38
- .description('Update dw-kit files in current project')
39
- .option('-n, --dry-run', 'Preview changes without applying')
40
- .option('-c, --check', 'Only check if update is available')
41
- .option('-l, --layer <name>', 'Update specific layer: core | platform | capability | all', 'all')
42
- .action(async (opts) => {
43
- const { upgradeCommand } = await import('./commands/upgrade.mjs');
44
- await upgradeCommand(opts);
45
- });
46
-
47
- program
48
- .command('validate')
49
- .description('Validate .dw/config/dw.config.yml against schema')
50
- .option('-f, --file <path>', 'Config file path', '.dw/config/dw.config.yml')
51
- .action(async (opts) => {
52
- const { validateCommand } = await import('./commands/validate.mjs');
53
- await validateCommand(opts);
54
- });
55
-
56
- program
57
- .command('doctor')
58
- .description('Check dw-kit installation health')
59
- .action(async () => {
60
- const { doctorCommand } = await import('./commands/doctor.mjs');
61
- await doctorCommand();
62
- });
63
-
64
- program
65
- .command('prompt')
66
- .description('Build a well-structured task prompt with autocomplete + guided wizard')
67
- .option('-t, --text <text>', 'Non-interactive: provide description directly')
68
- .action(async (opts) => {
69
- const { promptCommand } = await import('./commands/prompt.mjs');
70
- await promptCommand(opts);
71
- });
72
-
73
- program
74
- .command('claude-vn-fix')
75
- .description('Patch Claude CLI to fix Vietnamese IME (local, with backup/restore)')
76
- .option('--path <file>', 'Path to @anthropic-ai/claude-code/cli.js (optional; auto-detect if omitted)')
77
- .option('--restore', 'Restore from latest backup')
78
- .option('--dry-run', 'Show what would change without writing')
79
- .action(async (opts) => {
80
- const { claudeVnFixCommand } = await import('./commands/claude-vn-fix.mjs');
81
- await claudeVnFixCommand(opts);
82
- });
83
-
84
- program.parse(argv);
85
-
86
- if (latestVersion) {
87
- console.log();
88
- console.log(chalk.yellow(` ↑ Update available`) + ` v${pkg.version} ` + chalk.green.bold(`v${latestVersion}`));
89
- console.log(` Run ` + chalk.cyan(`npm install -g dw-kit`) + ` to update`);
90
- console.log();
91
- }
92
- }
1
+ import { Command } from 'commander';
2
+ import { createRequire } from 'node:module';
3
+ import { fileURLToPath } from 'node:url';
4
+ import { dirname, join } from 'node:path';
5
+ import chalk from 'chalk';
6
+ import { getUpdateNotice, scheduleUpdateCheck } from './lib/update-checker.mjs';
7
+
8
+ const __filename = fileURLToPath(import.meta.url);
9
+ const __dirname = dirname(__filename);
10
+ const require = createRequire(import.meta.url);
11
+ const pkg = require(join(__dirname, '..', 'package.json'));
12
+ const RELEASES_URL = 'https://github.com/dv-workflow/dv-workflow/releases';
13
+
14
+ export function run(argv) {
15
+ // Schedule fresh check in background (non-blocking).
16
+ // Notice is shown via process.on('exit') so it always appears AFTER command output,
17
+ // even when commands call process.exit() internally.
18
+ scheduleUpdateCheck(pkg.version);
19
+ const latestVersion = getUpdateNotice(pkg.version);
20
+
21
+ const program = new Command();
22
+
23
+ program
24
+ .name('dw')
25
+ .description('dw-kit — AI development workflow toolkit')
26
+ .version(pkg.version, '-v, --version');
27
+
28
+ program
29
+ .command('init')
30
+ .description('Setup dw-kit in current project (interactive wizard)')
31
+ .option('-p, --preset <name>', 'Use preset: solo-quick | small-team | enterprise')
32
+ .option('-a, --adapter <platform>', 'Target platform: claude-cli | cursor | generic', 'claude-cli')
33
+ .option('-s, --silent', 'Non-interactive mode (reads DW_NAME, DW_DEPTH, DW_ROLES, DW_LANG env vars)')
34
+ .action(async (opts) => {
35
+ const { initCommand } = await import('./commands/init.mjs');
36
+ await initCommand(opts);
37
+ });
38
+
39
+ program
40
+ .command('upgrade')
41
+ .description('Update dw-kit files in current project')
42
+ .option('-n, --dry-run', 'Preview changes without applying')
43
+ .option('-c, --check', 'Only check if update is available')
44
+ .option('-l, --layer <name>', 'Update specific layer: core | platform | capability | all', 'all')
45
+ .action(async (opts) => {
46
+ const { upgradeCommand } = await import('./commands/upgrade.mjs');
47
+ await upgradeCommand(opts);
48
+ });
49
+
50
+ program
51
+ .command('validate')
52
+ .description('Validate .dw/config/dw.config.yml against schema')
53
+ .option('-f, --file <path>', 'Config file path', '.dw/config/dw.config.yml')
54
+ .action(async (opts) => {
55
+ const { validateCommand } = await import('./commands/validate.mjs');
56
+ await validateCommand(opts);
57
+ });
58
+
59
+ program
60
+ .command('doctor')
61
+ .description('Check dw-kit installation health')
62
+ .action(async () => {
63
+ const { doctorCommand } = await import('./commands/doctor.mjs');
64
+ await doctorCommand();
65
+ });
66
+
67
+ program
68
+ .command('prompt')
69
+ .description('Build a well-structured task prompt with autocomplete + guided wizard')
70
+ .option('-t, --text <text>', 'Non-interactive: provide description directly')
71
+ .action(async (opts) => {
72
+ const { promptCommand } = await import('./commands/prompt.mjs');
73
+ await promptCommand(opts);
74
+ });
75
+
76
+ program
77
+ .command('claude-vn-fix')
78
+ .description('Patch Claude CLI to fix Vietnamese IME (local, with backup/restore)')
79
+ .option('--path <file>', 'Path to @anthropic-ai/claude-code/cli.js (optional; auto-detect if omitted)')
80
+ .option('--restore', 'Restore from latest backup')
81
+ .option('--dry-run', 'Show what would change without writing')
82
+ .action(async (opts) => {
83
+ const { claudeVnFixCommand } = await import('./commands/claude-vn-fix.mjs');
84
+ await claudeVnFixCommand(opts);
85
+ });
86
+
87
+ if (latestVersion) {
88
+ // Register notice to print AFTER the command completes (on clean exit only)
89
+ process.on('exit', (code) => {
90
+ if (code !== 0) return;
91
+ console.log();
92
+ console.log(chalk.yellow(` ↑ Update available`) + ` v${pkg.version} → ` + chalk.green.bold(`v${latestVersion}`));
93
+ console.log(` Run ` + chalk.cyan(`npm install -g dw-kit`) + ` to update`);
94
+ console.log(` Changelog: ` + chalk.cyan(`${RELEASES_URL}/tag/v${latestVersion}`));
95
+ console.log();
96
+ });
97
+ }
98
+
99
+ program.parse(argv);
100
+ }