@brunosps00/dev-workflow 0.15.0 → 1.0.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 +97 -119
- package/lib/constants.js +16 -36
- package/lib/migrate-skills.js +11 -4
- package/lib/removed-commands.js +30 -0
- package/package.json +1 -1
- package/scaffold/en/agent-instructions.md +27 -16
- package/scaffold/en/commands/dw-adr.md +2 -2
- package/scaffold/en/commands/dw-analyze-project.md +7 -7
- package/scaffold/en/commands/dw-autopilot.md +20 -20
- package/scaffold/en/commands/dw-brainstorm.md +160 -9
- package/scaffold/en/commands/dw-bugfix.md +5 -5
- package/scaffold/en/commands/dw-commit.md +1 -1
- package/scaffold/en/commands/dw-dockerize.md +9 -9
- package/scaffold/en/commands/dw-find-skills.md +4 -4
- package/scaffold/en/commands/dw-functional-doc.md +1 -1
- package/scaffold/en/commands/dw-generate-pr.md +4 -4
- package/scaffold/en/commands/dw-help.md +95 -351
- package/scaffold/en/commands/dw-intel.md +76 -12
- package/scaffold/en/commands/dw-new-project.md +9 -9
- package/scaffold/en/commands/dw-plan.md +175 -0
- package/scaffold/en/commands/dw-qa.md +166 -0
- package/scaffold/en/commands/dw-redesign-ui.md +6 -6
- package/scaffold/en/commands/dw-review.md +198 -0
- package/scaffold/en/commands/dw-run.md +176 -0
- package/scaffold/en/commands/dw-secure-audit.md +222 -0
- package/scaffold/en/commands/dw-update.md +1 -1
- package/scaffold/en/references/playwright-patterns.md +1 -1
- package/scaffold/en/references/refactoring-catalog.md +1 -1
- package/scaffold/en/templates/brainstorm-matrix.md +1 -1
- package/scaffold/en/templates/idea-onepager.md +3 -3
- package/scaffold/en/templates/project-onepager.md +5 -5
- package/scaffold/pt-br/agent-instructions.md +27 -16
- package/scaffold/pt-br/commands/dw-adr.md +2 -2
- package/scaffold/pt-br/commands/dw-analyze-project.md +7 -7
- package/scaffold/pt-br/commands/dw-autopilot.md +20 -20
- package/scaffold/pt-br/commands/dw-brainstorm.md +160 -9
- package/scaffold/pt-br/commands/dw-bugfix.md +8 -8
- package/scaffold/pt-br/commands/dw-commit.md +1 -1
- package/scaffold/pt-br/commands/dw-dockerize.md +9 -9
- package/scaffold/pt-br/commands/dw-find-skills.md +4 -4
- package/scaffold/pt-br/commands/dw-functional-doc.md +1 -1
- package/scaffold/pt-br/commands/dw-generate-pr.md +4 -4
- package/scaffold/pt-br/commands/dw-help.md +97 -300
- package/scaffold/pt-br/commands/dw-intel.md +77 -13
- package/scaffold/pt-br/commands/dw-new-project.md +9 -9
- package/scaffold/pt-br/commands/dw-plan.md +175 -0
- package/scaffold/pt-br/commands/dw-qa.md +166 -0
- package/scaffold/pt-br/commands/dw-redesign-ui.md +6 -6
- package/scaffold/pt-br/commands/dw-review.md +198 -0
- package/scaffold/pt-br/commands/dw-run.md +176 -0
- package/scaffold/pt-br/commands/dw-secure-audit.md +222 -0
- package/scaffold/pt-br/commands/dw-update.md +1 -1
- package/scaffold/pt-br/references/playwright-patterns.md +1 -1
- package/scaffold/pt-br/references/refactoring-catalog.md +1 -1
- package/scaffold/pt-br/templates/brainstorm-matrix.md +1 -1
- package/scaffold/pt-br/templates/idea-onepager.md +3 -3
- package/scaffold/pt-br/templates/project-onepager.md +5 -5
- package/scaffold/pt-br/templates/tasks-template.md +1 -1
- package/scaffold/skills/api-testing-recipes/SKILL.md +6 -6
- package/scaffold/skills/api-testing-recipes/references/auth-patterns.md +1 -1
- package/scaffold/skills/api-testing-recipes/references/matrix-conventions.md +1 -1
- package/scaffold/skills/api-testing-recipes/references/openapi-driven.md +3 -3
- package/scaffold/skills/docker-compose-recipes/SKILL.md +1 -1
- package/scaffold/skills/dw-codebase-intel/SKILL.md +9 -9
- package/scaffold/skills/dw-codebase-intel/agents/intel-updater.md +4 -4
- package/scaffold/skills/dw-codebase-intel/references/api-design-discipline.md +1 -1
- package/scaffold/skills/dw-codebase-intel/references/incremental-update.md +5 -5
- package/scaffold/skills/dw-codebase-intel/references/intel-format.md +1 -1
- package/scaffold/skills/dw-codebase-intel/references/query-patterns.md +3 -3
- package/scaffold/skills/dw-council/SKILL.md +2 -2
- package/scaffold/skills/dw-debug-protocol/SKILL.md +5 -3
- package/scaffold/skills/dw-execute-phase/SKILL.md +16 -16
- package/scaffold/skills/dw-execute-phase/agents/executor.md +5 -5
- package/scaffold/skills/dw-execute-phase/agents/plan-checker.md +4 -4
- package/scaffold/skills/dw-execute-phase/references/atomic-commits.md +1 -1
- package/scaffold/skills/dw-execute-phase/references/plan-verification.md +2 -2
- package/scaffold/skills/dw-execute-phase/references/wave-coordination.md +1 -1
- package/scaffold/skills/dw-git-discipline/SKILL.md +5 -2
- package/scaffold/skills/dw-incident-response/SKILL.md +5 -1
- package/scaffold/skills/dw-llm-eval/SKILL.md +10 -8
- package/scaffold/skills/dw-memory/SKILL.md +2 -2
- package/scaffold/skills/dw-review-rigor/SKILL.md +5 -5
- package/scaffold/skills/dw-simplification/SKILL.md +4 -4
- package/scaffold/skills/dw-source-grounding/SKILL.md +1 -1
- package/scaffold/skills/dw-testing-discipline/SKILL.md +8 -6
- package/scaffold/skills/dw-testing-discipline/references/agent-guardrails.md +3 -3
- package/scaffold/skills/dw-testing-discipline/references/anti-patterns.md +2 -2
- package/scaffold/skills/dw-testing-discipline/references/core-rules.md +1 -1
- package/scaffold/skills/dw-testing-discipline/references/flaky-discipline.md +3 -3
- package/scaffold/skills/dw-testing-discipline/references/patterns.md +1 -1
- package/scaffold/skills/dw-testing-discipline/references/playwright-recipes.md +1 -1
- package/scaffold/skills/dw-ui-discipline/SKILL.md +8 -6
- package/scaffold/skills/dw-ui-discipline/references/accessibility-floor.md +2 -2
- package/scaffold/skills/dw-ui-discipline/references/hard-gate.md +1 -1
- package/scaffold/skills/dw-ui-discipline/references/state-matrix.md +1 -1
- package/scaffold/skills/dw-ui-discipline/references/visual-slop.md +2 -2
- package/scaffold/skills/dw-verify/SKILL.md +4 -4
- package/scaffold/skills/humanizer/SKILL.md +1 -7
- package/scaffold/skills/remotion-best-practices/SKILL.md +3 -1
- package/scaffold/skills/security-review/SKILL.md +1 -1
- package/scaffold/skills/security-review/languages/csharp.md +1 -1
- package/scaffold/skills/security-review/languages/rust.md +1 -1
- package/scaffold/skills/security-review/languages/typescript.md +1 -1
- package/scaffold/skills/vercel-react-best-practices/SKILL.md +3 -1
- package/scaffold/templates-overrides-readme.md +3 -3
- package/scaffold/en/commands/dw-code-review.md +0 -386
- package/scaffold/en/commands/dw-create-prd.md +0 -148
- package/scaffold/en/commands/dw-create-tasks.md +0 -201
- package/scaffold/en/commands/dw-create-techspec.md +0 -210
- package/scaffold/en/commands/dw-deep-research.md +0 -418
- package/scaffold/en/commands/dw-deps-audit.md +0 -327
- package/scaffold/en/commands/dw-fix-qa.md +0 -152
- package/scaffold/en/commands/dw-map-codebase.md +0 -125
- package/scaffold/en/commands/dw-refactoring-analysis.md +0 -340
- package/scaffold/en/commands/dw-revert-task.md +0 -114
- package/scaffold/en/commands/dw-review-implementation.md +0 -349
- package/scaffold/en/commands/dw-run-plan.md +0 -300
- package/scaffold/en/commands/dw-run-qa.md +0 -497
- package/scaffold/en/commands/dw-run-task.md +0 -209
- package/scaffold/en/commands/dw-security-check.md +0 -271
- package/scaffold/pt-br/commands/dw-code-review.md +0 -366
- package/scaffold/pt-br/commands/dw-create-prd.md +0 -148
- package/scaffold/pt-br/commands/dw-create-tasks.md +0 -201
- package/scaffold/pt-br/commands/dw-create-techspec.md +0 -208
- package/scaffold/pt-br/commands/dw-deep-research.md +0 -172
- package/scaffold/pt-br/commands/dw-deps-audit.md +0 -327
- package/scaffold/pt-br/commands/dw-fix-qa.md +0 -152
- package/scaffold/pt-br/commands/dw-map-codebase.md +0 -125
- package/scaffold/pt-br/commands/dw-refactoring-analysis.md +0 -340
- package/scaffold/pt-br/commands/dw-revert-task.md +0 -114
- package/scaffold/pt-br/commands/dw-review-implementation.md +0 -337
- package/scaffold/pt-br/commands/dw-run-plan.md +0 -296
- package/scaffold/pt-br/commands/dw-run-qa.md +0 -495
- package/scaffold/pt-br/commands/dw-run-task.md +0 -208
- package/scaffold/pt-br/commands/dw-security-check.md +0 -271
package/README.md
CHANGED
|
@@ -10,7 +10,7 @@ npx @brunosps00/dev-workflow init
|
|
|
10
10
|
|
|
11
11
|
This will:
|
|
12
12
|
1. Ask you to select a language (English or Portuguese)
|
|
13
|
-
2. Create `.dw/commands/` with
|
|
13
|
+
2. Create `.dw/commands/` with 20 workflow commands
|
|
14
14
|
3. Create `.dw/templates/` with document templates (PRD, TechSpec, Tasks, ADR, etc.)
|
|
15
15
|
4. Create `.dw/rules/` (populated by `/dw-analyze-project`)
|
|
16
16
|
5. Install bundled skills (`dw-verify`, `dw-memory`, `dw-review-rigor`, `dw-ui-discipline`, `dw-testing-discipline`, `security-review`, etc.) to `.agents/skills/`
|
|
@@ -26,132 +26,68 @@ npx @brunosps00/dev-workflow install-deps
|
|
|
26
26
|
|
|
27
27
|
## Commands
|
|
28
28
|
|
|
29
|
-
|
|
29
|
+
dev-workflow v1.0.0 ships **20 commands** organized into four tiers. Most users only invoke Tier 1 + Tier 2.
|
|
30
30
|
|
|
31
|
-
|
|
32
|
-
Facilitates structured ideation before opening a PRD or implementation. Explores multiple directions — conservative, balanced, and bold — with trade-offs for each, then converges on concrete next steps. **Product-aware**: when PRDs or rules exist, automatically reads them to produce a Feature Inventory and tags each option as `[IMPROVES: <feature>]`, `[CONSOLIDATES: <A>+<B>]`, or `[NEW]`. With optional `--onepager` flag, generates a durable one-pager at `.dw/spec/ideas/<slug>.md` that `/dw-create-prd` can consume to reduce clarification questions. Inspired by [`addyosmani/agent-skills@idea-refine`](https://skills.sh/addyosmani/agent-skills/idea-refine), adapted to product-level (features) rather than code-level grounding. No code is written or project files modified by the brainstorm itself.
|
|
31
|
+
### Tier 1 — Gateway (3)
|
|
33
32
|
|
|
34
|
-
|
|
35
|
-
|
|
33
|
+
| Command | When |
|
|
34
|
+
|---------|------|
|
|
35
|
+
| **`/dw-autopilot "wish"`** | Default entry point. Full pipeline (PRD → TechSpec → Tasks → Run → QA → Review → Commit → PR) with 3 approval gates. |
|
|
36
|
+
| **`/dw-bugfix "description"`** | A bug report or pasted error. Triages bug-vs-feature-vs-scope, surgical fix or routes to a PRD. |
|
|
37
|
+
| **`/dw-help [keyword]`** | Discover commands. Pass a keyword for shortcuts; `--advanced` reveals internal commands. |
|
|
36
38
|
|
|
37
|
-
|
|
38
|
-
Creates a Product Requirements Document by first asking at least 7 clarification questions to fully understand the feature. Generates a structured PRD with numbered functional requirements focused on what and why, saved to `.dw/spec/prd-[feature-name]/prd.md`.
|
|
39
|
+
### Tier 2 — Pipeline granular (7)
|
|
39
40
|
|
|
40
|
-
|
|
41
|
-
Generates a Technical Specification from an existing PRD after performing web searches and asking at least 7 clarification questions. Evaluates existing libraries vs custom development, defines testing strategy, branch naming, and integration architecture. Output is saved to `.dw/spec/prd-[feature-name]/techspec.md`.
|
|
41
|
+
Use these when you want step-by-step control instead of `/dw-autopilot`.
|
|
42
42
|
|
|
43
|
-
|
|
44
|
-
|
|
43
|
+
| Command | What |
|
|
44
|
+
|---------|------|
|
|
45
|
+
| **`/dw-brainstorm "idea"`** | Refine an idea before PRD. Flags: `--onepager` (durable artifact), `--council` (multi-advisor debate), `--research` (multi-source cited research), `--refactor` (Fowler code-smell catalog). |
|
|
46
|
+
| **`/dw-plan "feature"`** | PRD → TechSpec → Tasks sequentially with checkpoints. Stages: `prd`, `techspec`, `tasks`. Mandatory clarification questions, source-grounding, constitution gate, final consistency check. |
|
|
47
|
+
| **`/dw-run [task-id]`** | Execute tasks. Default: all pending in dependency order with wave-based parallel dispatch. Single-task: pass an ID. `--resume` continues an interrupted plan. |
|
|
48
|
+
| **`/dw-review`** | Level 2 (PRD coverage mapping) + Level 3 (code quality). Hard gates on dw-verify PASS, secure-audit, constitution violations. Flags: `--coverage-only`, `--code-only`. |
|
|
49
|
+
| **`/dw-qa`** | Mode-aware QA. Auto-detects UI vs API. Flags: `--fix` (iterative QA + fix-retest loop), `--api`, `--ai` (run AI eval against reference dataset). |
|
|
50
|
+
| **`/dw-commit`** | Atomic Conventional Commits for pending changes. Applies `dw-git-discipline` (one intent per commit, lint+tests+build green before). |
|
|
51
|
+
| **`/dw-generate-pr [target]`** | Push the branch, draft a PR body with summary + test plan, open the browser. Hard gates: dw-verify PASS + secure-audit. |
|
|
45
52
|
|
|
46
|
-
###
|
|
53
|
+
### Tier 3 — Specialty (5)
|
|
47
54
|
|
|
48
|
-
|
|
49
|
-
|
|
55
|
+
| Command | What |
|
|
56
|
+
|---------|------|
|
|
57
|
+
| **`/dw-analyze-project`** | Scans the repo, writes `.dw/rules/` (per-module conventions, anti-patterns, naming). Step 8 offers to generate `.dw/constitution.md` (declarative principles the team commits to). Run once per project; refresh after major refactors. |
|
|
58
|
+
| **`/dw-redesign-ui "target"`** | Audits a frontend page, runs the `dw-ui-discipline` 4-question grounding, proposes 2-3 design directions, ships the redesign. WCAG 2.2 AA accessibility floor is non-negotiable. |
|
|
59
|
+
| **`/dw-functional-doc`** | Maps screens + user flows into a functional doc, validated end-to-end with Playwright. |
|
|
60
|
+
| **`/dw-new-project`** | Bootstrap a new project from empty directory. Stack interview, wraps official `create-*` tools, composes docker-compose for dev, seeds `.env`, scripts, CI, `.dw/rules/`. |
|
|
61
|
+
| **`/dw-dockerize`** | Reads existing project, detects stack + runtime deps, proposes Dockerfile + docker-compose for dev/prod with explicit trade-offs (Conservative/Balanced/Bold). |
|
|
50
62
|
|
|
51
|
-
|
|
52
|
-
Executes all pending tasks via the `dw-execute-phase` bundled skill — gated by 6-dimension goal-backward verification (`plan-checker` agent) before any code is touched. Wave-based parallel dispatch (`executor` agent) for independent tasks; atomic commit per task; deviation handling. After all tasks complete, performs a final Level 2 review (PRD compliance) with an interactive corrections cycle until no gaps remain or the user accepts pending items.
|
|
63
|
+
### Tier 4 — Hidden/Internal (5)
|
|
53
64
|
|
|
54
|
-
|
|
55
|
-
Analyzes and fixes bugs with automatic triage that distinguishes between bugs, feature requests, and excessive scope. Asks exactly 3 clarification questions before proposing a solution. Supports Direct mode (executes fix immediately) and Analysis mode (`--analysis`) that generates a document for the techspec/tasks pipeline.
|
|
65
|
+
These are auto-invoked by Tier 1-3 commands. Available standalone via `/dw-help --advanced`.
|
|
56
66
|
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
#### `/dw-fix-qa`
|
|
66
|
-
Fixes bugs found during QA testing with evidence-driven retesting. **Mode-aware**: in UI mode replays the failing flow via Playwright MCP and saves a retest screenshot; in API mode replays the failing `.http`/recipe and appends a `verdict: PASS|FAIL` JSONL line to `QA/logs/api/BUG-NN-retest.log`. Runs iterative cycles of identify, fix, retest, updating `QA/bugs.md` and `QA/qa-report.md` with status and mode-correct evidence.
|
|
67
|
-
|
|
68
|
-
#### `/dw-review-implementation`
|
|
69
|
-
Compares documented requirements (PRD + TechSpec + Tasks) against actual code as a Level 2 review. Maps each requirement to endpoints and tasks with evidence, identifies gaps, partial implementations, and extra undocumented code. After the coverage map is complete, automatically chains `/dw-code-review` (Level 3 quality layer) so a single invocation produces a consolidated coverage + quality report — pass `--no-code-review` if you want only Level 2.
|
|
70
|
-
|
|
71
|
-
#### `/dw-code-review`
|
|
72
|
-
Performs a formal Level 3 code review before PR creation, verifying PRD compliance, code quality (SOLID, DRY, complexity, security), and conformance with project rules in `.dw/rules/`. Runs tests, verifies coverage targets, and generates a persistent report with APPROVED, APPROVED WITH CAVEATS, or REJECTED status.
|
|
73
|
-
|
|
74
|
-
#### `/dw-refactoring-analysis`
|
|
75
|
-
Audits the codebase for code smells and refactoring opportunities using Martin Fowler's catalog. Detects bloaters, change preventers, dispensables, couplers, conditional complexity, and DRY violations, then maps each to a concrete refactoring technique with before/after code sketches. Includes coupling/cohesion metrics, SOLID analysis, and a prioritized action plan (P0-P3).
|
|
76
|
-
|
|
77
|
-
#### `/dw-security-check`
|
|
78
|
-
Rigid multi-layer security check for **TypeScript, Python, C#, and Rust** projects. Combines OWASP static review (language-aware, via the bundled `security-review` skill), Trivy SCA/secret/IaC scanning (`trivy fs` + `trivy config`), and native lockfile audit (`npm audit` / `pip-audit` / `dotnet list package --vulnerable` / `cargo audit`). Consults Context7 MCP for framework-version-specific best practices (Next.js, Django, ASP.NET Core, Actix/Axum/Rocket, etc.). Hard gates: any CRITICAL or HIGH finding produces REJECTED status, blocking `/dw-code-review`, `/dw-review-implementation`, and `/dw-generate-pr`. No bypass flag. Requires Trivy (install via `install-deps`).
|
|
79
|
-
|
|
80
|
-
#### `/dw-deps-audit`
|
|
81
|
-
Supply-chain remediation orchestrator for **TypeScript, Python, C#, and Rust** projects. Runs three detection signals — `npm/pnpm/pip-audit/dotnet/cargo audit` for known CVEs, the `outdated` companions for stale versions, and an OSV.dev + GitHub Advisories cross-check (with a hardcoded fallback list of historical malicious-package incidents like `event-stream`, `ua-parser-js`, `node-ipc`) for supply-chain attacks. Classifies findings into COMPROMISED / CRITICAL / HIGH / OUTDATED-MAJOR / OUTDATED-MINOR tiers, maps each affected package to the files that import it and the tests that cover those files, then drafts a per-package update plan with three options (Conservative / Balanced / Bold) and trade-offs. Modes: `--scan-only` (CI), `--plan` (default — no file writes), `--execute` (applies updates with scoped tests, one `/dw-fix-qa` retry, atomic commits, and `/dw-run-qa` as final gate; reverts and marks BLOCKED if recovery fails). Complementary to `/dw-security-check`: that one is the single-shot gate, this one is the planner-and-remediator.
|
|
82
|
-
|
|
83
|
-
### Git & PR
|
|
84
|
-
|
|
85
|
-
#### `/dw-commit`
|
|
86
|
-
Analyzes pending changes, groups them by feature or logical context, and creates atomic semantic commits following the Conventional Commits format. Uses allowed types: `feat`, `fix`, `docs`, `style`, `refactor`, `perf`, `test`, `chore`, `ci`, `build`.
|
|
87
|
-
|
|
88
|
-
#### `/dw-generate-pr`
|
|
89
|
-
Pushes the branch to remote and creates a Pull Request on GitHub with a structured description. Collects information from the PRD and modified files, runs tests, then generates a PR body with summary, changes grouped by module, test plan, and deploy notes. **Hard gate**: requires a fresh `dw-verify` PASS in the current session before the push.
|
|
90
|
-
|
|
91
|
-
#### `/dw-revert-task`
|
|
92
|
-
Safely reverts the commits of a specific task created by `/dw-run-task`, with dependency-aware checks (blocks if subsequent tasks already executed depend on it) and explicit user confirmation. Updates `tasks.md` to re-mark the task as pending.
|
|
93
|
-
|
|
94
|
-
### Project Bootstrap
|
|
95
|
-
|
|
96
|
-
#### `/dw-new-project`
|
|
97
|
-
Bootstraps a new project from an empty directory. Runs a wide stack interview (frontend/backend/fullstack, language, framework, db, cache, queue, email, storage, search, auth, observability, reverse proxy, scheduler, CI, linter), then wraps the right official `create-*` tools (`pnpm create next-app`, `pnpm create vite`, `pnpm dlx create-t3-app`, `dotnet new webapi`, `cargo new`, etc.) to scaffold the apps. Composes a `docker-compose.dev.yml` from the bundled `docker-compose-recipes` skill (postgres, redis, mailhog by default for email-in-dev, minio, meilisearch, jaeger, traefik, etc.), seeds `.env.example`, root scripts (`dev:up`/`down`/`logs`/`reset`), `.gitignore`/`.dockerignore`, GitHub Action, README with port table, and a minimal `.dw/rules/index.md`. Hard gate: presents a one-pager + plan and waits for explicit approval before touching disk.
|
|
98
|
-
|
|
99
|
-
### Containerization
|
|
100
|
-
|
|
101
|
-
#### `/dw-dockerize`
|
|
102
|
-
Reads an existing project, detects language / framework / package manager / runtime infra deps (postgres, redis, queue, email, storage, search, OTel) by parsing manifests and import statements, then proposes Docker artifacts. Modes: `--dev` (default if no Dockerfile exists) generates `docker-compose.dev.yml` + `Dockerfile.dev` from the bundled `docker-compose-recipes` skill; `--prod` generates a multi-stage `Dockerfile` (Conservative slim / Balanced alpine / Bold distroless — brainstormed with trade-offs) + optional `docker-compose.prod.yml` with non-root user, healthcheck, no secrets baked in; `--both` ships both; `--audit` (default if Docker artifacts already exist) reports findings against `security-review/infrastructure/docker.md` without overwriting. Hard gate: presents the file tree and waits for approval before any write. Sister command to `/dw-new-project` — they share the `docker-compose-recipes` bundled skill.
|
|
103
|
-
|
|
104
|
-
### Architectural Decisions
|
|
105
|
-
|
|
106
|
-
#### `/dw-adr`
|
|
107
|
-
Records an Architecture Decision Record (ADR) for a non-trivial decision during PRD execution. Creates `.dw/spec/<prd>/adrs/adr-NNN.md` with Context / Decision / Alternatives / Consequences, and updates cross-references in the PRD/TechSpec/Task. Inspired by the ADR pattern from [Compozy](https://github.com/compozy/compozy).
|
|
108
|
-
|
|
109
|
-
### Intelligence
|
|
110
|
-
|
|
111
|
-
#### `/dw-intel`
|
|
112
|
-
Queries codebase intelligence to answer questions about patterns, conventions, and architecture. Reads `.dw/intel/` (built by `/dw-map-codebase`) as primary source, falls back to `.dw/rules/` and direct grep when absent. Surfaces stale-index warnings (>7 days). Always cites sources with file paths and line numbers.
|
|
113
|
-
|
|
114
|
-
#### `/dw-analyze-project`
|
|
115
|
-
Scans the repository to identify tech stack, architectural patterns, naming conventions, and anti-patterns. Generates structured documentation in `.dw/rules/` with a project overview (`index.md`) and per-module rule files containing real code examples. Also invokes `/dw-map-codebase` to build the queryable index in `.dw/intel/` (the two are complementary — rules are human-readable, intel is machine-queryable).
|
|
116
|
-
|
|
117
|
-
#### `/dw-deep-research`
|
|
118
|
-
Conducts multi-source research with citation tracking and verification across quick, standard, deep, and ultradeep modes. Executes parallel information gathering, triangulation, and cross-reference verification through 8+ phases, producing a professional report with complete bibliography.
|
|
119
|
-
|
|
120
|
-
#### `/dw-functional-doc`
|
|
121
|
-
Generates a functional documentation dossier with screen mapping, E2E flows, and Playwright validation. Maps routes, components, and user journeys into structured documentation with evidence.
|
|
122
|
-
|
|
123
|
-
#### `/dw-help`
|
|
124
|
-
Displays the complete guide of available commands, integration flows, and when to use each one. Can be invoked without arguments for the full guide or with a specific command name for a detailed section.
|
|
125
|
-
|
|
126
|
-
#### `/dw-find-skills`
|
|
127
|
-
Discovers skills from the open agent skills ecosystem (`npx skills` / [skills.sh](https://skills.sh/)) when no `dw-*` already covers the request. Checks the leaderboard first, then runs `npx skills find <query>` if needed, vets each candidate (install count, source reputation, GitHub stars), and presents 1–3 options with the install commands. Asks whether to install globally (`-g`, lands in `~/.agents/skills/`) or locally (this repo) before running `npx skills add`. Falls back to `/dw-brainstorm` or `/dw-run-task` when no skill matches. Ports the `find-skills` Claude superpowers skill into a `dw-*` command so every supported platform gets the same discovery on-ramp.
|
|
67
|
+
| Command | What | Invoked by |
|
|
68
|
+
|---------|------|------------|
|
|
69
|
+
| **`/dw-adr "decision"`** | Records an Architecture Decision Record at `.dw/spec/<prd>/adrs/`. | `/dw-plan techspec --council`; deviations from constitution |
|
|
70
|
+
| **`/dw-intel "question"`** | Query codebase intelligence (`.dw/intel/`). `--build` (re)creates the index. | `/dw-plan`, `/dw-review`, `/dw-bugfix` |
|
|
71
|
+
| **`/dw-secure-audit`** | Unified security: OWASP + Trivy SCA/secret/IaC + lockfile + supply-chain check. Hard gate. Flags: `--scan-only`, `--plan`, `--execute`. | `/dw-review`, `/dw-generate-pr` (for TS/Python/C#/Rust) |
|
|
72
|
+
| **`/dw-find-skills "query"`** | Searches `npx skills` ecosystem, vets, installs. | manual when extending the bundle |
|
|
73
|
+
| **`/dw-update`** | Updates dev-workflow to latest npm release with rollback snapshot. | manual maintenance |
|
|
128
74
|
|
|
129
75
|
## Workflow
|
|
130
76
|
|
|
131
77
|
```
|
|
132
78
|
/dw-autopilot "wish" ------> Runs entire pipeline automatically
|
|
133
|
-
(gates: PRD approval, Tasks approval, PR confirmation)
|
|
134
|
-
--- OR ---
|
|
135
|
-
|
|
136
|
-
/dw-brainstorm
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
|
146
|
-
/dw-run-qa --> .dw/spec/prd-{name}/QA/
|
|
147
|
-
|
|
|
148
|
-
/dw-fix-qa (if bugs found)
|
|
149
|
-
|
|
|
150
|
-
/dw-review-implementation --> PRD compliance check
|
|
151
|
-
|
|
|
152
|
-
/dw-code-review --> .dw/spec/prd-{name}/QA/dw-code-review.md
|
|
153
|
-
|
|
|
154
|
-
/dw-commit + /dw-generate-pr
|
|
79
|
+
(3 gates: PRD approval, Tasks approval, PR confirmation)
|
|
80
|
+
--- OR step-by-step ---
|
|
81
|
+
|
|
82
|
+
/dw-brainstorm --> /dw-plan --> .dw/spec/prd-{name}/{prd,techspec,tasks}.md
|
|
83
|
+
|
|
|
84
|
+
/dw-run --> atomic commits per task, dependency-aware
|
|
85
|
+
|
|
|
86
|
+
/dw-qa --> .dw/spec/prd-{name}/QA/ (UI / API / --ai)
|
|
87
|
+
|
|
|
88
|
+
/dw-review --> L2 PRD coverage + L3 code quality
|
|
89
|
+
|
|
|
90
|
+
/dw-commit + /dw-generate-pr
|
|
155
91
|
|
|
156
92
|
Shortcuts:
|
|
157
93
|
/dw-intel "question" Query codebase intelligence
|
|
@@ -227,7 +163,7 @@ All wrappers point to `.dw/commands/` as the single source of truth.
|
|
|
227
163
|
```
|
|
228
164
|
your-project/
|
|
229
165
|
├── .dw/
|
|
230
|
-
│ ├── commands/ #
|
|
166
|
+
│ ├── commands/ # 20 workflow command files (v1.0.0)
|
|
231
167
|
│ ├── templates/ # Document templates (PRD, TechSpec, etc.)
|
|
232
168
|
│ │ └── overrides/ # Project-local template customizations (override > core)
|
|
233
169
|
│ ├── rules/ # Project-specific rules (run /dw-analyze-project)
|
|
@@ -326,16 +262,58 @@ Incident response (`dw-incident-response`) adapted from [`wilsto/claude-code-sta
|
|
|
326
262
|
|
|
327
263
|
LLM evaluation (`dw-llm-eval`) trajectory-match modes (strict / unordered / subset / superset) and tool-argument matching strategies adapted from [`langchain-ai/agentevals`](https://github.com/langchain-ai/agentevals) (MIT). The broader oracle-ladder framing, judge-calibration discipline, and reference-dataset principle are distilled from the open evaluations literature (OpenAI evals cookbook, Anthropic evals guidance, the academic eval-of-LLM body of work) and rewritten in our voice.
|
|
328
264
|
|
|
329
|
-
## Migration from v0.
|
|
265
|
+
## Migration from v0.x (1.0.0 is a consolidation release)
|
|
266
|
+
|
|
267
|
+
v1.0.0 consolidates 30 commands → 20. **The `dev-workflow update` command auto-removes obsolete wrappers** via the migrator that landed in v0.13.0; no manual action required.
|
|
268
|
+
|
|
269
|
+
### Command renames (15 → 7 merged)
|
|
270
|
+
|
|
271
|
+
| Old (v0.x) | New (v1.0.0) |
|
|
272
|
+
|-----------|--------------|
|
|
273
|
+
| `/dw-create-prd` | `/dw-plan prd` |
|
|
274
|
+
| `/dw-create-techspec` | `/dw-plan techspec` |
|
|
275
|
+
| `/dw-create-tasks` | `/dw-plan tasks` |
|
|
276
|
+
| `/dw-run-task <id>` | `/dw-run <id>` |
|
|
277
|
+
| `/dw-run-plan` | `/dw-run` |
|
|
278
|
+
| `/dw-code-review` | `/dw-review --code-only` |
|
|
279
|
+
| `/dw-review-implementation` | `/dw-review --coverage-only` |
|
|
280
|
+
| `/dw-run-qa` | `/dw-qa` |
|
|
281
|
+
| `/dw-fix-qa` | `/dw-qa --fix` |
|
|
282
|
+
| `/dw-security-check` | `/dw-secure-audit` |
|
|
283
|
+
| `/dw-deps-audit` | `/dw-secure-audit --plan` |
|
|
284
|
+
| `/dw-map-codebase` | `/dw-intel --build` |
|
|
285
|
+
| `/dw-deep-research` | `/dw-brainstorm --research` |
|
|
286
|
+
| `/dw-refactoring-analysis` | `/dw-brainstorm --refactor` |
|
|
287
|
+
|
|
288
|
+
### Removed (1)
|
|
289
|
+
|
|
290
|
+
- `/dw-revert-task` → use `git revert <sha>` directly. No replacement.
|
|
291
|
+
|
|
292
|
+
### Bundled skill swaps (already shipped in v0.13.0; carries over)
|
|
293
|
+
|
|
294
|
+
- `ui-ux-pro-max` → `dw-ui-discipline`
|
|
295
|
+
- `webapp-testing` → `dw-testing-discipline`
|
|
296
|
+
|
|
297
|
+
### What the migrator does for you
|
|
298
|
+
|
|
299
|
+
On the next `npx @brunosps00/dev-workflow update`, the following happens automatically:
|
|
300
|
+
|
|
301
|
+
1. The 15 renamed commands' wrappers are detected as orphans (their names no longer exist in `lib/constants.js`) and removed from `.claude/skills/`, `.agents/skills/`, and `.opencode/commands/`.
|
|
302
|
+
2. The migrator prints each removal with the friendly "old → new" mapping (e.g., `[orphan] Removing wrapper .agents/skills/dw-create-prd (replaced in v1.0.0 by 'dw-plan prd')`).
|
|
303
|
+
3. The 20 new wrappers are installed for the consolidated commands.
|
|
304
|
+
4. The 17 bundled skills are refreshed.
|
|
305
|
+
|
|
306
|
+
### Backwards compatibility
|
|
307
|
+
|
|
308
|
+
**There is none** — v1.0.0 is a clean cut per design. There are no aliases. Calling `/dw-create-prd` will not work; use `/dw-plan prd`. Update your team's runbooks and AI-agent instructions (CLAUDE.md / AGENTS.md) accordingly; the auto-trigger map in `agent-instructions.md` is already updated.
|
|
330
309
|
|
|
331
|
-
|
|
310
|
+
### CLAUDE.md / AGENTS.md updates
|
|
332
311
|
|
|
333
|
-
|
|
334
|
-
- `webapp-testing` → replaced by `dw-testing-discipline` (auto-removed on update)
|
|
312
|
+
The Trigger Map block (between `<!-- dev-workflow:start -->` and `<!-- dev-workflow:end -->`) refreshes automatically on update with the v1.0.0 command surface. Your edits outside the markers are preserved.
|
|
335
313
|
|
|
336
|
-
|
|
314
|
+
### Skill conventions
|
|
337
315
|
|
|
338
|
-
|
|
316
|
+
Skill description format ("pushy" trigger phrases ≤200 chars, "Use when X. Triggers on Y." pattern) and structural conventions (`SKILL.md` + `references/` / `scripts/` / `assets/` / `agents/` subdirectories, explicit `allowed-tools` in frontmatter) follow the official guidance from [`anthropics/skills/skill-creator`](https://github.com/anthropics/skills/tree/main/skills/skill-creator) (Apache 2.0). dev-workflow's 20 bundled skills are not derived from skill-creator's content — only its conventions are followed for auto-trigger reliability across Claude Code, Codex CLI, Copilot, and OpenCode.
|
|
339
317
|
|
|
340
318
|
## License
|
|
341
319
|
|
package/lib/constants.js
CHANGED
|
@@ -3,64 +3,44 @@ const COMMANDS = {
|
|
|
3
3
|
{ name: 'dw-adr', description: 'Records an architectural decision and the trade-offs accepted, before they get lost.' },
|
|
4
4
|
{ name: 'dw-analyze-project', description: 'Scans the repo to learn its stack and conventions, then writes the rules other commands rely on.' },
|
|
5
5
|
{ name: 'dw-autopilot', description: 'Trigger when user asks to implement, build, create, or add a feature non-trivially. Runs full PRD-to-PR pipeline with three gates.' },
|
|
6
|
-
{ name: 'dw-brainstorm', description: '
|
|
6
|
+
{ name: 'dw-brainstorm', description: 'Refine an idea against the product\'s existing features. Modes: default ideation, --research (multi-source cited research), --refactor (Fowler code-smell catalog), --onepager, --council.' },
|
|
7
7
|
{ name: 'dw-bugfix', description: 'Trigger when user reports a bug, pastes an error, or describes broken behavior. Triages with three questions, then fixes or routes to PRD.' },
|
|
8
|
-
{ name: 'dw-code-review', description: 'Trigger when user asks to review code, check quality, or verify PR readiness. Level-3 review with APPROVED/REJECTED verdict.' },
|
|
9
8
|
{ name: 'dw-commit', description: 'Trigger when implementation is complete and pending changes need to be committed. Atomic commits with Conventional Commits messages.' },
|
|
10
|
-
{ name: 'dw-create-prd', description: 'Trigger when user has a feature idea and needs a written spec before implementation. Asks the questions a techspec would otherwise inherit.' },
|
|
11
|
-
{ name: 'dw-create-tasks', description: 'Trigger after PRD + techspec exist and the team is ready to break work into shippable units. Includes a 5-dimension consistency check.' },
|
|
12
|
-
{ name: 'dw-create-techspec', description: 'Trigger when a PRD is approved and architecture must be defined before tasks. Adds framework choices, test strategy, and constitution alignment.' },
|
|
13
|
-
{ name: 'dw-deep-research', description: 'Researches a topic across sources, tracks citations, and flags claims that don\'t check out.' },
|
|
14
|
-
{ name: 'dw-deps-audit', description: 'Finds outdated and supply-chain-compromised packages, drafts a per-package update plan, and runs scoped QA after each upgrade.' },
|
|
15
9
|
{ name: 'dw-dockerize', description: 'Reads a project, detects the stack and runtime deps, then proposes Dockerfile and docker-compose for dev and prod with explicit trade-offs.' },
|
|
16
10
|
{ name: 'dw-find-skills', description: 'Searches the npx skills ecosystem for a skill matching what you need, vets it, and installs it where you choose.' },
|
|
17
|
-
{ name: 'dw-fix-qa', description: 'Fixes bugs found in QA and retests them with screenshot evidence until they stay fixed.' },
|
|
18
11
|
{ name: 'dw-functional-doc', description: 'Maps screens and user flows into a functional doc, validated end-to-end with Playwright.' },
|
|
19
12
|
{ name: 'dw-generate-pr', description: 'Trigger when commits are ready and the branch needs a PR. Pushes branch and opens PR with summary + test plan + hard verify gate.' },
|
|
20
|
-
{ name: 'dw-help', description: 'Lists
|
|
21
|
-
{ name: 'dw-intel', description: '
|
|
22
|
-
{ name: 'dw-map-codebase', description: 'Builds a queryable index in .dw/intel/ (stack, files, apis, deps, arch) so other commands stop re-exploring the codebase.' },
|
|
13
|
+
{ name: 'dw-help', description: 'Lists primary commands and the flows that connect them. Pass --advanced to see internal/hidden commands.' },
|
|
14
|
+
{ name: 'dw-intel', description: 'Codebase intelligence: query mode (default) answers questions citing .dw/intel/ + .dw/rules/; --build mode (re)builds the index.' },
|
|
23
15
|
{ name: 'dw-new-project', description: 'Interviews you about stack and infra, then scaffolds a working monorepo with docker-compose for dev, .env, scripts, CI, and seeded rules.' },
|
|
16
|
+
{ name: 'dw-plan', description: 'Trigger when user has a feature idea and needs spec + architecture + tasks. Runs PRD → TechSpec → Tasks sequentially. Stages: prd / techspec / tasks; --from techspec; --council.' },
|
|
17
|
+
{ name: 'dw-qa', description: 'Trigger when user wants to validate behavior beyond unit tests. Mode-aware (UI / API / --ai). --fix enters the iterative QA + fix-retest loop.' },
|
|
24
18
|
{ name: 'dw-redesign-ui', description: 'Audits a frontend page, proposes design directions you choose from, then ships the redesign.' },
|
|
25
|
-
{ name: 'dw-
|
|
26
|
-
{ name: 'dw-
|
|
27
|
-
{ name: 'dw-
|
|
28
|
-
{ name: 'dw-run-plan', description: 'Trigger when user wants to execute all pending tasks. Goal-backward plan check, then wave-based parallel execution with atomic commits.' },
|
|
29
|
-
{ name: 'dw-run-qa', description: 'Drives the browser to test happy paths, edge cases, and accessibility, with screenshot proof.' },
|
|
30
|
-
{ name: 'dw-run-task', description: 'Trigger when user wants to execute one specific task by ID. Implements, validates with mandatory tests, commits when passing.' },
|
|
31
|
-
{ name: 'dw-security-check', description: 'OWASP review plus Trivy CVE/secret/IaC scan for TS, Python, C#, or Rust. CRITICAL or HIGH blocks the PR.' },
|
|
19
|
+
{ name: 'dw-review', description: 'Trigger when user asks to review code, check quality, or verify PR readiness. Default runs L2 (PRD coverage) + L3 (code quality). Flags --coverage-only / --code-only.' },
|
|
20
|
+
{ name: 'dw-run', description: 'Trigger when user wants to execute tasks. Default runs all pending in dependency order; \'run <task-id>\' runs one; \'run --resume\' continues an interrupted plan.' },
|
|
21
|
+
{ name: 'dw-secure-audit', description: 'Unified security audit: OWASP + Trivy SCA/secret/IaC + lockfile + supply-chain compromise check. Hidden; auto-invoked by /dw-review and /dw-generate-pr.' },
|
|
32
22
|
{ name: 'dw-update', description: 'Updates dev-workflow to the latest npm release in-place, with a snapshot you can roll back to.' },
|
|
33
23
|
],
|
|
34
24
|
'pt-br': [
|
|
35
25
|
{ name: 'dw-adr', description: 'Registra uma decisao arquitetural e os trade-offs aceitos, antes que se percam.' },
|
|
36
26
|
{ name: 'dw-analyze-project', description: 'Escaneia o repo para aprender stack e convencoes, e escreve as regras que os outros commands usam.' },
|
|
37
27
|
{ name: 'dw-autopilot', description: 'Trigger quando usuario pede pra implementar, criar ou adicionar uma feature nao-trivial. Roda pipeline completo PRD-ao-PR com tres gates.' },
|
|
38
|
-
{ name: 'dw-brainstorm', description: 'Refina uma ideia
|
|
28
|
+
{ name: 'dw-brainstorm', description: 'Refina uma ideia contra features existentes do produto. Modos: ideacao default, --research (research multi-fonte citada), --refactor (catalogo de code smells Fowler), --onepager, --council.' },
|
|
39
29
|
{ name: 'dw-bugfix', description: 'Trigger quando usuario reporta bug, cola erro ou descreve comportamento quebrado. Tria com tres perguntas, depois corrige ou roteia pra PRD.' },
|
|
40
|
-
{ name: 'dw-code-review', description: 'Trigger quando usuario pede pra revisar codigo, checar qualidade ou validar prontidao pra PR. Review Nivel 3 com veredicto APROVADO/REPROVADO.' },
|
|
41
30
|
{ name: 'dw-commit', description: 'Trigger quando implementacao esta completa e ha mudancas pendentes pra commit. Commits atomicos com mensagens Conventional Commits.' },
|
|
42
|
-
{ name: 'dw-create-prd', description: 'Trigger quando usuario tem ideia de feature e precisa de spec escrito antes de implementar. Faz as perguntas que o techspec herdaria.' },
|
|
43
|
-
{ name: 'dw-create-tasks', description: 'Trigger depois que PRD + techspec existem e o time vai quebrar em unidades entregaveis. Inclui consistency check em 5 dimensoes.' },
|
|
44
|
-
{ name: 'dw-create-techspec', description: 'Trigger quando PRD esta aprovado e arquitetura precisa ser definida antes das tasks. Adiciona escolhas de framework, testes e alinhamento de constitution.' },
|
|
45
|
-
{ name: 'dw-deep-research', description: 'Pesquisa um topico em varias fontes, rastreia citacoes e marca o que nao confere.' },
|
|
46
|
-
{ name: 'dw-deps-audit', description: 'Encontra pacotes desatualizados e comprometidos por supply-chain, monta plano de update por pacote e roda QA do que foi afetado.' },
|
|
47
31
|
{ name: 'dw-dockerize', description: 'Le um projeto, detecta stack e deps de runtime, e propoe Dockerfile e docker-compose para dev e prod com trade-offs explicitos.' },
|
|
48
32
|
{ name: 'dw-find-skills', description: 'Busca no ecossistema npx skills uma skill que resolva o que voce precisa, valida e instala onde voce escolher.' },
|
|
49
|
-
{ name: 'dw-fix-qa', description: 'Corrige bugs do QA e retesta com evidencia em screenshot ate ficarem estaveis.' },
|
|
50
33
|
{ name: 'dw-functional-doc', description: 'Mapeia telas e fluxos em um dossie funcional, validado E2E com Playwright.' },
|
|
51
34
|
{ name: 'dw-generate-pr', description: 'Trigger quando commits estao prontos e branch precisa de PR. Push da branch e abre PR com summary + test plan + hard verify gate.' },
|
|
52
|
-
{ name: 'dw-help', description: 'Lista
|
|
53
|
-
{ name: 'dw-intel', description: '
|
|
54
|
-
{ name: 'dw-map-codebase', description: 'Constroi um indice queryable em .dw/intel/ (stack, files, apis, deps, arch) para outros comandos pararem de re-explorar o codebase.' },
|
|
35
|
+
{ name: 'dw-help', description: 'Lista comandos primarios e fluxos que os conectam. Passe --advanced para ver comandos internos/escondidos.' },
|
|
36
|
+
{ name: 'dw-intel', description: 'Inteligencia do codebase: modo query (default) responde citando .dw/intel/ + .dw/rules/; modo --build (re)constroi indice.' },
|
|
55
37
|
{ name: 'dw-new-project', description: 'Entrevista voce sobre stack e infra, depois faz scaffold de um monorepo com docker-compose para dev, .env, scripts, CI e rules seed.' },
|
|
38
|
+
{ name: 'dw-plan', description: 'Trigger quando usuario tem ideia de feature e precisa spec + arquitetura + tasks. Roda PRD → TechSpec → Tasks sequencial. Stages: prd / techspec / tasks; --from techspec; --council.' },
|
|
39
|
+
{ name: 'dw-qa', description: 'Trigger quando usuario quer validar comportamento alem de unit tests. Mode-aware (UI / API / --ai). --fix entra no loop iterativo QA + fix-retest.' },
|
|
56
40
|
{ name: 'dw-redesign-ui', description: 'Audita uma pagina frontend, propoe direcoes de design que voce escolhe, e entrega o redesign.' },
|
|
57
|
-
{ name: 'dw-
|
|
58
|
-
{ name: 'dw-
|
|
59
|
-
{ name: 'dw-
|
|
60
|
-
{ name: 'dw-run-plan', description: 'Trigger quando usuario quer executar todas as tasks pendentes. Plan check goal-backward, depois execucao paralela em ondas com commits atomicos.' },
|
|
61
|
-
{ name: 'dw-run-qa', description: 'Pilota o browser para testar fluxo feliz, edge cases e acessibilidade, com screenshot.' },
|
|
62
|
-
{ name: 'dw-run-task', description: 'Trigger quando usuario quer executar uma task especifica por ID. Implementa, valida com testes obrigatorios, commita quando passa.' },
|
|
63
|
-
{ name: 'dw-security-check', description: 'Review OWASP + scan Trivy CVE/secret/IaC para TS, Python, C# ou Rust. CRITICAL ou HIGH bloqueia PR.' },
|
|
41
|
+
{ name: 'dw-review', description: 'Trigger quando usuario pede pra revisar codigo, checar qualidade ou validar prontidao pra PR. Default roda L2 (cobertura PRD) + L3 (qualidade). Flags --coverage-only / --code-only.' },
|
|
42
|
+
{ name: 'dw-run', description: 'Trigger quando usuario quer executar tasks. Default roda todas pendentes em ordem de dependencia; \'run <task-id>\' roda uma; \'run --resume\' continua plan interrompido.' },
|
|
43
|
+
{ name: 'dw-secure-audit', description: 'Audit unificado de seguranca: OWASP + Trivy SCA/secret/IaC + lockfile + supply-chain compromise. Hidden; auto-invocado por /dw-review e /dw-generate-pr.' },
|
|
64
44
|
{ name: 'dw-update', description: 'Atualiza o dev-workflow para o release mais recente no npm, com snapshot para rollback.' },
|
|
65
45
|
],
|
|
66
46
|
};
|
package/lib/migrate-skills.js
CHANGED
|
@@ -2,6 +2,7 @@ const fs = require('fs');
|
|
|
2
2
|
const path = require('path');
|
|
3
3
|
const { COMMANDS } = require('./constants');
|
|
4
4
|
const removedSkills = require('./removed-bundled-skills');
|
|
5
|
+
const removedCommands = require('./removed-commands');
|
|
5
6
|
|
|
6
7
|
/**
|
|
7
8
|
* Cleanup-on-update for dev-workflow.
|
|
@@ -41,11 +42,17 @@ function migrate(projectRoot) {
|
|
|
41
42
|
rmRecursive(entry.path);
|
|
42
43
|
}
|
|
43
44
|
|
|
45
|
+
// Pre-build a map { commandName -> { removedIn, replacedBy } } for friendly messaging.
|
|
46
|
+
const removedCommandMap = new Map(removedCommands.map((r) => [r.name, r]));
|
|
47
|
+
|
|
44
48
|
for (const entry of orphans) {
|
|
45
49
|
const rel = path.relative(projectRoot, entry.path);
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
50
|
+
const baseName = entry.commandName;
|
|
51
|
+
const known = baseName ? removedCommandMap.get(baseName) : null;
|
|
52
|
+
const suffix = known
|
|
53
|
+
? `(replaced in v${known.removedIn} by \`${known.replacedBy}\`)`
|
|
54
|
+
: `(command no longer exists)`;
|
|
55
|
+
console.log(` \x1b[33m-\x1b[0m [orphan] Removing wrapper ${rel} ${suffix}`);
|
|
49
56
|
rmRecursive(entry.path);
|
|
50
57
|
}
|
|
51
58
|
|
|
@@ -114,7 +121,7 @@ function scanOrphanCommandWrappers(projectRoot) {
|
|
|
114
121
|
const isExpected = loc.type === 'directory' ? entry.isDirectory() : entry.isFile();
|
|
115
122
|
if (!isExpected) continue;
|
|
116
123
|
|
|
117
|
-
orphans.push({ path: path.join(loc.dir, entry.name) });
|
|
124
|
+
orphans.push({ path: path.join(loc.dir, entry.name), commandName: name });
|
|
118
125
|
}
|
|
119
126
|
}
|
|
120
127
|
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Manifest of dw-* commands removed in past releases.
|
|
3
|
+
*
|
|
4
|
+
* APPEND-ONLY: never modify or remove entries. A removed command stays
|
|
5
|
+
* in this manifest forever so old installs still get cleaned up when
|
|
6
|
+
* the user runs `dev-workflow update`.
|
|
7
|
+
*
|
|
8
|
+
* Each entry surfaces a friendly "old → new" message during migrate-skills
|
|
9
|
+
* orphan-wrapper sweep. The mapping is informational — the actual cleanup
|
|
10
|
+
* is the generic orphan-wrapper scan that already matches dw-* names
|
|
11
|
+
* against the current `lib/constants.js`.
|
|
12
|
+
*/
|
|
13
|
+
module.exports = [
|
|
14
|
+
// v1.0.0 — pipeline consolidation
|
|
15
|
+
{ name: 'dw-create-prd', removedIn: '1.0.0', replacedBy: 'dw-plan prd' },
|
|
16
|
+
{ name: 'dw-create-techspec', removedIn: '1.0.0', replacedBy: 'dw-plan techspec' },
|
|
17
|
+
{ name: 'dw-create-tasks', removedIn: '1.0.0', replacedBy: 'dw-plan tasks' },
|
|
18
|
+
{ name: 'dw-run-task', removedIn: '1.0.0', replacedBy: 'dw-run <task-id>' },
|
|
19
|
+
{ name: 'dw-run-plan', removedIn: '1.0.0', replacedBy: 'dw-run' },
|
|
20
|
+
{ name: 'dw-code-review', removedIn: '1.0.0', replacedBy: 'dw-review --code-only' },
|
|
21
|
+
{ name: 'dw-review-implementation', removedIn: '1.0.0', replacedBy: 'dw-review --coverage-only' },
|
|
22
|
+
{ name: 'dw-run-qa', removedIn: '1.0.0', replacedBy: 'dw-qa' },
|
|
23
|
+
{ name: 'dw-fix-qa', removedIn: '1.0.0', replacedBy: 'dw-qa --fix' },
|
|
24
|
+
{ name: 'dw-security-check', removedIn: '1.0.0', replacedBy: 'dw-secure-audit' },
|
|
25
|
+
{ name: 'dw-deps-audit', removedIn: '1.0.0', replacedBy: 'dw-secure-audit --plan' },
|
|
26
|
+
{ name: 'dw-map-codebase', removedIn: '1.0.0', replacedBy: 'dw-intel --build' },
|
|
27
|
+
{ name: 'dw-deep-research', removedIn: '1.0.0', replacedBy: 'dw-brainstorm --research' },
|
|
28
|
+
{ name: 'dw-refactoring-analysis', removedIn: '1.0.0', replacedBy: 'dw-brainstorm --refactor' },
|
|
29
|
+
{ name: 'dw-revert-task', removedIn: '1.0.0', replacedBy: 'git revert <sha>' },
|
|
30
|
+
];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@brunosps00/dev-workflow",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "1.0.0",
|
|
4
4
|
"description": "AI-driven development workflow commands for any project. Scaffolds a complete PRD-to-PR pipeline with multi-platform AI assistant support.",
|
|
5
5
|
"bin": {
|
|
6
6
|
"dev-workflow": "./bin/dev-workflow.js"
|
|
@@ -11,28 +11,42 @@ This project uses [`@brunosps00/dev-workflow`](https://www.npmjs.com/package/@br
|
|
|
11
11
|
|--------------------------------------|--------------|
|
|
12
12
|
| "Implement X" / "Build Y" / "Add feature Z" / "I need ..." / "Create ..." | `/dw-autopilot "X"` |
|
|
13
13
|
| Pasted error / "X is broken" / "Bug in Y" / failing test screenshot | `/dw-bugfix "X"` |
|
|
14
|
-
| "
|
|
15
|
-
| "
|
|
16
|
-
| "
|
|
14
|
+
| "Plan this feature" / "Write a PRD + techspec + tasks" | `/dw-plan "X"` |
|
|
15
|
+
| "Write a PRD for X" / "Spec out Y" | `/dw-plan prd "X"` |
|
|
16
|
+
| "Design the architecture" / "Make the techspec" | `/dw-plan techspec` |
|
|
17
|
+
| "Break this into tasks" | `/dw-plan tasks` |
|
|
18
|
+
| "Run this task" (with task ID) | `/dw-run <ID>` |
|
|
19
|
+
| "Run all pending tasks" / "Execute the plan" | `/dw-run` |
|
|
20
|
+
| "Continue where I left off" | `/dw-run --resume` |
|
|
21
|
+
| "QA this feature" / "Run the test plan" | `/dw-qa` |
|
|
22
|
+
| "Fix the QA bugs" | `/dw-qa --fix` |
|
|
23
|
+
| "Evaluate the AI feature" / "Test the RAG / classifier" | `/dw-qa --ai` |
|
|
24
|
+
| "Review my PR" / "Check code quality" / "Is this ready to ship?" | `/dw-review` |
|
|
25
|
+
| "Just the PRD coverage check" | `/dw-review --coverage-only` |
|
|
26
|
+
| "Just the code quality review" | `/dw-review --code-only` |
|
|
17
27
|
| "Time to commit" / changes are validated and ready | `/dw-commit` |
|
|
18
28
|
| "Open a PR" / "Ship this" | `/dw-generate-pr` |
|
|
19
|
-
| "
|
|
20
|
-
| "
|
|
21
|
-
| "
|
|
29
|
+
| "Brainstorm X" / "Explore ideas" | `/dw-brainstorm "X"` |
|
|
30
|
+
| "Research X" / "Compare A vs B with citations" | `/dw-brainstorm --research "X"` |
|
|
31
|
+
| "Code-health audit" / "Find tech debt" / "Refactoring opportunities" | `/dw-brainstorm --refactor` |
|
|
22
32
|
| "Where is X?" / "What uses Y?" / "How is Z structured?" | `/dw-intel "<question>"` |
|
|
23
|
-
| "
|
|
24
|
-
| "
|
|
25
|
-
| "
|
|
26
|
-
| "
|
|
33
|
+
| "Rebuild the codebase index" / "Refresh intel" | `/dw-intel --build` |
|
|
34
|
+
| "Redesign this UI" / "Audit and ship a new design" | `/dw-redesign-ui "<target>"` |
|
|
35
|
+
| "Audit dependencies" / "Are we behind on packages?" | `/dw-secure-audit --plan` |
|
|
36
|
+
| "Scan for vulnerabilities" / "Security check" | `/dw-secure-audit` |
|
|
37
|
+
| "Analyze this project" / "Generate rules" | `/dw-analyze-project` |
|
|
38
|
+
| "Open a new project" / "Bootstrap a stack" | `/dw-new-project` |
|
|
39
|
+
| "Dockerize this" / "Add docker-compose" | `/dw-dockerize` |
|
|
40
|
+
| "Functional doc" / "Map screens and flows" | `/dw-functional-doc` |
|
|
27
41
|
|
|
28
42
|
**Priority:** when in doubt between two commands, `/dw-autopilot` is the safest default for any non-trivial feature request — it composes the rest.
|
|
29
43
|
|
|
30
44
|
## Hard Gates (the commands enforce these — don't bypass)
|
|
31
45
|
|
|
32
46
|
- **`.dw/constitution.md`**: principles with `severity: high` or `critical` block PRs / techspecs without an ADR justifying the deviation. Missing constitution? Commands auto-install defaults at `severity: info` (non-blocking) and continue — never blocks on absence.
|
|
33
|
-
- **`.dw/spec/<prd>/tasks-validation.md`**: auto-generated at the end of `/dw-
|
|
47
|
+
- **`.dw/spec/<prd>/tasks-validation.md`**: auto-generated at the end of `/dw-plan tasks`. Any FAIL dimension blocks user approval until resolved or explicitly overridden.
|
|
34
48
|
- **Verification**: `/dw-generate-pr` requires a fresh `dw-verify` PASS (tests + lint + build) after the last edit.
|
|
35
|
-
- **Security**: TS / Python / C# / Rust projects must pass `/dw-
|
|
49
|
+
- **Security**: TS / Python / C# / Rust projects must pass `/dw-secure-audit` (Trivy + OWASP + lockfile audit) before the PR opens.
|
|
36
50
|
|
|
37
51
|
## Escape Hatches — do NOT auto-trigger
|
|
38
52
|
|
|
@@ -52,10 +66,7 @@ When any of these apply, answer directly and do **not** invoke a `dw-*` command:
|
|
|
52
66
|
|
|
53
67
|
--- OR step-by-step ---
|
|
54
68
|
|
|
55
|
-
/dw-brainstorm ─► /dw-
|
|
56
|
-
│
|
|
57
|
-
▼
|
|
58
|
-
/dw-commit + /dw-generate-pr ◄──── /dw-code-review ◄──── /dw-run-plan
|
|
69
|
+
/dw-brainstorm ─► /dw-plan ─► /dw-run ─► /dw-qa ─► /dw-review ─► /dw-commit ─► /dw-generate-pr
|
|
59
70
|
```
|
|
60
71
|
|
|
61
72
|
Full command list and contextual help: `/dw-help`.
|
|
@@ -3,12 +3,12 @@ You are an architectural-decision recorder. Your job is to create an **Architect
|
|
|
3
3
|
|
|
4
4
|
## When to Use
|
|
5
5
|
- Use when an architectural or design decision has been made and needs to be recorded for future reference (library choice, communication pattern, performance tradeoff, compliance-imposed constraint, etc.)
|
|
6
|
-
- Use during `/dw-
|
|
6
|
+
- Use during `/dw-plan techspec` or `/dw-run` when the rationale for the decision does not fit in the techspec or the task file
|
|
7
7
|
- Do NOT use for trivial or cheaply-reversible decisions (variable names, import order)
|
|
8
8
|
- Do NOT use to record bugs or incidents (use `/dw-bugfix` or operational notes)
|
|
9
9
|
|
|
10
10
|
## Pipeline Position
|
|
11
|
-
**Predecessor:** any point in the pipeline after `/dw-
|
|
11
|
+
**Predecessor:** any point in the pipeline after `/dw-plan prd` | **Successor:** continue the previous flow (techspec, task, review)
|
|
12
12
|
|
|
13
13
|
The ADR is **additive**: it does not replace any pipeline stage. Any existing command can invoke `/dw-adr` when a non-trivial decision needs a permanent record.
|
|
14
14
|
|
|
@@ -24,10 +24,10 @@ You are a project analysis specialist. Your task is to scan the current reposito
|
|
|
24
24
|
|
|
25
25
|
## Output Consumers
|
|
26
26
|
The rules generated by this command are consumed by:
|
|
27
|
-
- `/dw-run
|
|
28
|
-
- `/dw-code-
|
|
29
|
-
- `/dw-
|
|
30
|
-
- `/dw-
|
|
27
|
+
- `/dw-run` -- reads rules for implementation patterns
|
|
28
|
+
- `/dw-review --code-only` -- reads rules for conformance checks
|
|
29
|
+
- `/dw-brainstorm --refactor` -- reads rules for project context
|
|
30
|
+
- `/dw-plan techspec` -- reads rules for architecture decisions
|
|
31
31
|
|
|
32
32
|
<critical>This command ONLY generates documentation. Do NOT modify any project source code.</critical>
|
|
33
33
|
<critical>Read actual source files to verify patterns — do not guess from file names alone.</critical>
|
|
@@ -230,13 +230,13 @@ For each module/project detected, identify:
|
|
|
230
230
|
When React is detected, run `npx react-doctor@latest --verbose` and include the health score in the generated rules as a baseline metric.
|
|
231
231
|
For Angular projects, run `ng lint` and document any warnings as baseline.
|
|
232
232
|
|
|
233
|
-
<critical>Running /dw-
|
|
233
|
+
<critical>Running /dw-intel --build to generate the queryable index in .dw/intel/ is MANDATORY. The command CANNOT be considered complete without it.</critical>
|
|
234
234
|
|
|
235
235
|
#### Codebase Intelligence (native)
|
|
236
236
|
|
|
237
|
-
After generating rules in `.dw/rules/`, delegate to `/dw-
|
|
237
|
+
After generating rules in `.dw/rules/`, delegate to `/dw-intel --build` to create the queryable index in `.dw/intel/`:
|
|
238
238
|
- The index includes: stack (`stack.json`), file graph (`files.json`), API surface (`apis.json`), dependencies (`deps.json`), architecture overview (`arch.md`)
|
|
239
|
-
- The index is incremental — `/dw-
|
|
239
|
+
- The index is incremental — `/dw-intel --build --files <list>` updates only the touched entries; full scan only when needed
|
|
240
240
|
- Other dw-* commands query the index via `/dw-intel` (see the `dw-codebase-intel` bundled skill for schemas)
|
|
241
241
|
|
|
242
242
|
### Step 4: Detect Code Patterns and Conventions
|