mindforge-cc 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/.agent/CLAUDE.md +462 -0
- package/.agent/forge/help.md +7 -0
- package/.agent/forge/init-project.md +32 -0
- package/.agent/forge/plan-phase.md +30 -0
- package/.agent/mindforge/approve.md +18 -0
- package/.agent/mindforge/audit.md +30 -0
- package/.agent/mindforge/benchmark.md +33 -0
- package/.agent/mindforge/complete-milestone.md +18 -0
- package/.agent/mindforge/debug.md +126 -0
- package/.agent/mindforge/discuss-phase.md +138 -0
- package/.agent/mindforge/execute-phase.md +165 -0
- package/.agent/mindforge/health.md +21 -0
- package/.agent/mindforge/help.md +23 -0
- package/.agent/mindforge/init-org.md +131 -0
- package/.agent/mindforge/init-project.md +155 -0
- package/.agent/mindforge/install-skill.md +15 -0
- package/.agent/mindforge/map-codebase.md +298 -0
- package/.agent/mindforge/metrics.md +22 -0
- package/.agent/mindforge/migrate.md +40 -0
- package/.agent/mindforge/milestone.md +12 -0
- package/.agent/mindforge/next.md +105 -0
- package/.agent/mindforge/plan-phase.md +125 -0
- package/.agent/mindforge/plugins.md +40 -0
- package/.agent/mindforge/pr-review.md +41 -0
- package/.agent/mindforge/profile-team.md +23 -0
- package/.agent/mindforge/publish-skill.md +19 -0
- package/.agent/mindforge/quick.md +135 -0
- package/.agent/mindforge/release.md +10 -0
- package/.agent/mindforge/retrospective.md +26 -0
- package/.agent/mindforge/review.md +157 -0
- package/.agent/mindforge/security-scan.md +233 -0
- package/.agent/mindforge/ship.md +100 -0
- package/.agent/mindforge/skills.md +141 -0
- package/.agent/mindforge/status.md +104 -0
- package/.agent/mindforge/sync-confluence.md +11 -0
- package/.agent/mindforge/sync-jira.md +12 -0
- package/.agent/mindforge/tokens.md +8 -0
- package/.agent/mindforge/update.md +42 -0
- package/.agent/mindforge/verify-phase.md +62 -0
- package/.agent/mindforge/workspace.md +29 -0
- package/.claude/CLAUDE.md +462 -0
- package/.claude/commands/forge/help.md +7 -0
- package/.claude/commands/forge/init-project.md +32 -0
- package/.claude/commands/forge/plan-phase.md +30 -0
- package/.claude/commands/mindforge/approve.md +18 -0
- package/.claude/commands/mindforge/audit.md +30 -0
- package/.claude/commands/mindforge/benchmark.md +33 -0
- package/.claude/commands/mindforge/complete-milestone.md +18 -0
- package/.claude/commands/mindforge/debug.md +126 -0
- package/.claude/commands/mindforge/discuss-phase.md +138 -0
- package/.claude/commands/mindforge/execute-phase.md +165 -0
- package/.claude/commands/mindforge/health.md +21 -0
- package/.claude/commands/mindforge/help.md +23 -0
- package/.claude/commands/mindforge/init-org.md +131 -0
- package/.claude/commands/mindforge/init-project.md +155 -0
- package/.claude/commands/mindforge/install-skill.md +15 -0
- package/.claude/commands/mindforge/map-codebase.md +298 -0
- package/.claude/commands/mindforge/metrics.md +22 -0
- package/.claude/commands/mindforge/migrate.md +40 -0
- package/.claude/commands/mindforge/milestone.md +12 -0
- package/.claude/commands/mindforge/next.md +105 -0
- package/.claude/commands/mindforge/plan-phase.md +125 -0
- package/.claude/commands/mindforge/plugins.md +40 -0
- package/.claude/commands/mindforge/pr-review.md +41 -0
- package/.claude/commands/mindforge/profile-team.md +23 -0
- package/.claude/commands/mindforge/publish-skill.md +19 -0
- package/.claude/commands/mindforge/quick.md +135 -0
- package/.claude/commands/mindforge/release.md +10 -0
- package/.claude/commands/mindforge/retrospective.md +26 -0
- package/.claude/commands/mindforge/review.md +157 -0
- package/.claude/commands/mindforge/security-scan.md +233 -0
- package/.claude/commands/mindforge/ship.md +100 -0
- package/.claude/commands/mindforge/skills.md +141 -0
- package/.claude/commands/mindforge/status.md +104 -0
- package/.claude/commands/mindforge/sync-confluence.md +11 -0
- package/.claude/commands/mindforge/sync-jira.md +12 -0
- package/.claude/commands/mindforge/tokens.md +8 -0
- package/.claude/commands/mindforge/update.md +42 -0
- package/.claude/commands/mindforge/verify-phase.md +62 -0
- package/.claude/commands/mindforge/workspace.md +29 -0
- package/.forge/org/CONVENTIONS.md +0 -0
- package/.forge/org/ORG.md +0 -0
- package/.forge/org/SECURITY.md +0 -0
- package/.forge/org/TOOLS.md +0 -0
- package/.forge/personas/analyst.md +0 -0
- package/.forge/personas/architect.md +0 -0
- package/.forge/personas/debug-specialist.md +0 -0
- package/.forge/personas/developer.md +26 -0
- package/.forge/personas/qa-engineer.md +0 -0
- package/.forge/personas/release-manager.md +0 -0
- package/.forge/personas/security-reviewer.md +33 -0
- package/.forge/personas/tech-writer.md +0 -0
- package/.forge/skills/api-design/SKILL.md +0 -0
- package/.forge/skills/code-quality/SKILL.md +0 -0
- package/.forge/skills/documentation/SKILL.md +0 -0
- package/.forge/skills/security-review/SKILL.md +23 -0
- package/.forge/skills/testing-standards/SKILL.md +27 -0
- package/.github/workflows/mindforge-ci.yml +224 -0
- package/.gitlab-ci-mindforge.yml +18 -0
- package/.mindforge/MINDFORGE-SCHEMA.json +165 -0
- package/.mindforge/audit/AUDIT-SCHEMA.md +451 -0
- package/.mindforge/ci/ci-config-schema.md +21 -0
- package/.mindforge/ci/ci-mode.md +179 -0
- package/.mindforge/ci/github-actions-adapter.md +224 -0
- package/.mindforge/ci/gitlab-ci-adapter.md +31 -0
- package/.mindforge/ci/jenkins-adapter.md +44 -0
- package/.mindforge/distribution/registry-client.md +166 -0
- package/.mindforge/distribution/registry-schema.md +96 -0
- package/.mindforge/distribution/skill-publisher.md +44 -0
- package/.mindforge/distribution/skill-validator.md +74 -0
- package/.mindforge/engine/compaction-protocol.md +182 -0
- package/.mindforge/engine/context-injector.md +128 -0
- package/.mindforge/engine/dependency-parser.md +113 -0
- package/.mindforge/engine/skills/conflict-resolver.md +69 -0
- package/.mindforge/engine/skills/loader.md +184 -0
- package/.mindforge/engine/skills/registry.md +98 -0
- package/.mindforge/engine/skills/versioning.md +75 -0
- package/.mindforge/engine/verification-pipeline.md +111 -0
- package/.mindforge/engine/wave-executor.md +235 -0
- package/.mindforge/governance/GOVERNANCE-CONFIG.md +17 -0
- package/.mindforge/governance/approval-workflow.md +37 -0
- package/.mindforge/governance/change-classifier.md +63 -0
- package/.mindforge/governance/compliance-gates.md +31 -0
- package/.mindforge/integrations/confluence.md +27 -0
- package/.mindforge/integrations/connection-manager.md +163 -0
- package/.mindforge/integrations/github.md +25 -0
- package/.mindforge/integrations/gitlab.md +13 -0
- package/.mindforge/integrations/jira.md +102 -0
- package/.mindforge/integrations/slack.md +41 -0
- package/.mindforge/intelligence/antipattern-detector.md +75 -0
- package/.mindforge/intelligence/difficulty-scorer.md +55 -0
- package/.mindforge/intelligence/health-engine.md +208 -0
- package/.mindforge/intelligence/skill-gap-analyser.md +40 -0
- package/.mindforge/intelligence/smart-compaction.md +71 -0
- package/.mindforge/metrics/METRICS-SCHEMA.md +42 -0
- package/.mindforge/metrics/quality-tracker.md +32 -0
- package/.mindforge/monorepo/cross-package-planner.md +114 -0
- package/.mindforge/monorepo/dependency-graph-builder.md +32 -0
- package/.mindforge/monorepo/workspace-detector.md +129 -0
- package/.mindforge/org/CONVENTIONS.md +62 -0
- package/.mindforge/org/ORG.md +51 -0
- package/.mindforge/org/SECURITY.md +50 -0
- package/.mindforge/org/TOOLS.md +53 -0
- package/.mindforge/org/integrations/INTEGRATIONS-CONFIG.md +58 -0
- package/.mindforge/org/skills/MANIFEST.md +38 -0
- package/.mindforge/personas/analyst.md +52 -0
- package/.mindforge/personas/architect.md +75 -0
- package/.mindforge/personas/debug-specialist.md +52 -0
- package/.mindforge/personas/developer.md +85 -0
- package/.mindforge/personas/overrides/README.md +85 -0
- package/.mindforge/personas/qa-engineer.md +61 -0
- package/.mindforge/personas/release-manager.md +76 -0
- package/.mindforge/personas/security-reviewer.md +91 -0
- package/.mindforge/personas/tech-writer.md +51 -0
- package/.mindforge/plugins/PLUGINS-MANIFEST.md +23 -0
- package/.mindforge/plugins/plugin-loader.md +93 -0
- package/.mindforge/plugins/plugin-registry.md +44 -0
- package/.mindforge/plugins/plugin-schema.md +68 -0
- package/.mindforge/pr-review/ai-reviewer.md +266 -0
- package/.mindforge/pr-review/finding-formatter.md +46 -0
- package/.mindforge/pr-review/review-prompt-templates.md +44 -0
- package/.mindforge/production/compatibility-layer.md +39 -0
- package/.mindforge/production/migration-engine.md +52 -0
- package/.mindforge/production/production-checklist.md +165 -0
- package/.mindforge/production/token-optimiser.md +68 -0
- package/.mindforge/skills/accessibility/SKILL.md +106 -0
- package/.mindforge/skills/api-design/SKILL.md +98 -0
- package/.mindforge/skills/code-quality/SKILL.md +88 -0
- package/.mindforge/skills/data-privacy/SKILL.md +126 -0
- package/.mindforge/skills/database-patterns/SKILL.md +192 -0
- package/.mindforge/skills/documentation/SKILL.md +91 -0
- package/.mindforge/skills/incident-response/SKILL.md +180 -0
- package/.mindforge/skills/performance/SKILL.md +120 -0
- package/.mindforge/skills/security-review/SKILL.md +83 -0
- package/.mindforge/skills/testing-standards/SKILL.md +97 -0
- package/.mindforge/team/TEAM-PROFILE.md +42 -0
- package/.mindforge/team/multi-handoff.md +23 -0
- package/.mindforge/team/profiles/README.md +13 -0
- package/.mindforge/team/session-merger.md +18 -0
- package/.planning/ARCHITECTURE.md +0 -0
- package/.planning/AUDIT.jsonl +0 -0
- package/.planning/HANDOFF.json +28 -0
- package/.planning/PROJECT.md +33 -0
- package/.planning/RELEASE-CHECKLIST.md +68 -0
- package/.planning/REQUIREMENTS.md +0 -0
- package/.planning/ROADMAP.md +0 -0
- package/.planning/STATE.md +31 -0
- package/.planning/approvals/.gitkeep +1 -0
- package/.planning/archive/.gitkeep +1 -0
- package/.planning/audit-archive/.gitkeep +1 -0
- package/.planning/decisions/.gitkeep +0 -0
- package/.planning/decisions/ADR-001-handoff-tracking.md +41 -0
- package/.planning/decisions/ADR-002-markdown-commands.md +46 -0
- package/.planning/decisions/ADR-003-skills-trigger-model.md +37 -0
- package/.planning/decisions/ADR-004-wave-parallelism-model.md +45 -0
- package/.planning/decisions/ADR-005-append-only-audit-log.md +51 -0
- package/.planning/decisions/ADR-006-tiered-skills-system.md +22 -0
- package/.planning/decisions/ADR-007-trigger-keyword-model.md +22 -0
- package/.planning/decisions/ADR-008-just-in-time-skill-loading.md +29 -0
- package/.planning/decisions/ADR-009-enterprise-integration-retry-policy.md +8 -0
- package/.planning/decisions/ADR-010-governance-tier-escalation.md +8 -0
- package/.planning/decisions/ADR-011-multi-developer-handoff-contract.md +8 -0
- package/.planning/decisions/ADR-012-intelligence-feedback-loops.md +19 -0
- package/.planning/decisions/ADR-013-mindforge-md-constitution.md +16 -0
- package/.planning/decisions/ADR-014-metrics-as-signals-not-evaluation.md +15 -0
- package/.planning/decisions/ADR-015-npm-based-skill-registry.md +26 -0
- package/.planning/decisions/ADR-016-ci-exit-code-0-on-timeout.md +27 -0
- package/.planning/decisions/ADR-017-sdk-localhost-only.md +28 -0
- package/.planning/decisions/ADR-018-installer-self-install-detection.md +15 -0
- package/.planning/decisions/ADR-019-self-update-scope-preservation.md +14 -0
- package/.planning/decisions/ADR-020-v1.0.0-stable-interface-contract.md +23 -0
- package/.planning/jira-sync.json +9 -0
- package/.planning/milestones/.gitkeep +1 -0
- package/.planning/phases/day1/REVIEW-DAY1.md +50 -0
- package/.planning/phases/day1/SECURITY-REVIEW-DAY1.md +15 -0
- package/.planning/phases/day2/REVIEW-DAY2.md +521 -0
- package/.planning/phases/day3/REVIEW-DAY3.md +234 -0
- package/.planning/slack-threads.json +6 -0
- package/CHANGELOG.md +175 -0
- package/LICENSE +21 -0
- package/MINDFORGE.md +76 -0
- package/README.md +182 -0
- package/RELEASENOTES.md +41 -0
- package/SECURITY.md +4 -0
- package/bin/install.js +120 -0
- package/bin/installer-core.js +292 -0
- package/bin/migrations/0.1.0-to-0.5.0.js +37 -0
- package/bin/migrations/0.5.0-to-0.6.0.js +17 -0
- package/bin/migrations/0.6.0-to-1.0.0.js +100 -0
- package/bin/migrations/migrate.js +151 -0
- package/bin/migrations/schema-versions.js +64 -0
- package/bin/updater/changelog-fetcher.js +62 -0
- package/bin/updater/self-update.js +169 -0
- package/bin/updater/version-comparator.js +68 -0
- package/bin/validate-config.js +92 -0
- package/bin/wizard/config-generator.js +112 -0
- package/bin/wizard/environment-detector.js +76 -0
- package/bin/wizard/setup-wizard.js +237 -0
- package/docs/Context/Master-Context.md +701 -0
- package/docs/architecture/README.md +35 -0
- package/docs/architecture/decision-records-index.md +26 -0
- package/docs/ci-cd-integration.md +30 -0
- package/docs/ci-quickstart.md +78 -0
- package/docs/commands-reference.md +11 -0
- package/docs/contributing/CONTRIBUTING.md +38 -0
- package/docs/contributing/plugin-authoring.md +50 -0
- package/docs/contributing/skill-authoring.md +41 -0
- package/docs/enterprise-setup.md +25 -0
- package/docs/faq.md +38 -0
- package/docs/getting-started.md +36 -0
- package/docs/governance-guide.md +23 -0
- package/docs/mindforge-md-reference.md +53 -0
- package/docs/monorepo-guide.md +26 -0
- package/docs/persona-customisation.md +56 -0
- package/docs/quick-verify.md +33 -0
- package/docs/reference/audit-events.md +53 -0
- package/docs/reference/commands.md +82 -0
- package/docs/reference/config-reference.md +64 -0
- package/docs/reference/sdk-api.md +48 -0
- package/docs/reference/skills-api.md +57 -0
- package/docs/release-checklist-guide.md +37 -0
- package/docs/requirements.md +29 -0
- package/docs/sdk-reference.md +27 -0
- package/docs/security/SECURITY.md +42 -0
- package/docs/security/penetration-test-results.md +31 -0
- package/docs/security/threat-model.md +142 -0
- package/docs/skills-authoring-guide.md +119 -0
- package/docs/skills-publishing-guide.md +21 -0
- package/docs/team-setup-guide.md +21 -0
- package/docs/troubleshooting.md +119 -0
- package/docs/tutorial.md +195 -0
- package/docs/upgrade.md +44 -0
- package/docs/user-guide.md +131 -0
- package/docs/usp-features.md +214 -0
- package/eslint.config.mjs +31 -0
- package/examples/starter-project/.planning/AUDIT.jsonl +1 -0
- package/examples/starter-project/.planning/HANDOFF.json +23 -0
- package/examples/starter-project/.planning/PROJECT.md +27 -0
- package/examples/starter-project/.planning/STATE.md +10 -0
- package/examples/starter-project/MINDFORGE.md +40 -0
- package/examples/starter-project/README.md +14 -0
- package/implementation-roadmap/day-1-imp/DAY1-HARDEN.md +823 -0
- package/implementation-roadmap/day-1-imp/DAY1-IMPLEMENT.md +2459 -0
- package/implementation-roadmap/day-1-imp/DAY1-REVIEW.md +288 -0
- package/implementation-roadmap/day-2-imp/DAY2-HARDEN.md +954 -0
- package/implementation-roadmap/day-2-imp/DAY2-IMPLEMENT.md +2347 -0
- package/implementation-roadmap/day-2-imp/DAY2-REVIEW.md +422 -0
- package/implementation-roadmap/day-3-imp/DAY3-HARDEN.md +870 -0
- package/implementation-roadmap/day-3-imp/DAY3-IMPLEMENT.md +2798 -0
- package/implementation-roadmap/day-3-imp/DAY3-REVIEW.md +484 -0
- package/implementation-roadmap/day-4-imp/DAY4-HARDEN.md +1087 -0
- package/implementation-roadmap/day-4-imp/DAY4-IMPLEMENT.md +2874 -0
- package/implementation-roadmap/day-4-imp/DAY4-REVIEW.md +386 -0
- package/implementation-roadmap/day-5-imp/DAY5-HARDEN.md +1078 -0
- package/implementation-roadmap/day-5-imp/DAY5-IMPLEMENT.md +3151 -0
- package/implementation-roadmap/day-5-imp/DAY5-REVIEW.md +345 -0
- package/implementation-roadmap/day-6-imp/DAY6-COMPLETE.md +3919 -0
- package/implementation-roadmap/day-7-imp-prod/DAY7-PRODUCTION-FINAL.md +4513 -0
- package/package.json +31 -0
- package/sdk/README.md +69 -0
- package/sdk/eslint.config.mjs +34 -0
- package/sdk/package-lock.json +1507 -0
- package/sdk/package.json +30 -0
- package/sdk/src/client.ts +133 -0
- package/sdk/src/commands.ts +63 -0
- package/sdk/src/events.ts +166 -0
- package/sdk/src/index.ts +22 -0
- package/sdk/src/types.ts +87 -0
- package/sdk/tsconfig.json +13 -0
- package/tests/audit.test.js +206 -0
- package/tests/ci-mode.test.js +162 -0
- package/tests/compaction.test.js +161 -0
- package/tests/distribution.test.js +205 -0
- package/tests/e2e.test.js +618 -0
- package/tests/governance.test.js +130 -0
- package/tests/install.test.js +209 -0
- package/tests/integrations.test.js +128 -0
- package/tests/intelligence.test.js +117 -0
- package/tests/metrics.test.js +96 -0
- package/tests/migration.test.js +309 -0
- package/tests/production.test.js +416 -0
- package/tests/sdk.test.js +200 -0
- package/tests/skills-platform.test.js +403 -0
- package/tests/wave-engine.test.js +338 -0
|
@@ -0,0 +1,233 @@
|
|
|
1
|
+
# MindForge — Security Scan Command
|
|
2
|
+
# Usage: /mindforge:security-scan [path] [--deep] [--deps] [--secrets]
|
|
3
|
+
# Standalone security scan. Can be run independently of the phase lifecycle.
|
|
4
|
+
|
|
5
|
+
## Scan modes
|
|
6
|
+
- Default: OWASP Top 10 review on the changed files or specified path
|
|
7
|
+
- `--deep`: Extended scan including all files, not just changed
|
|
8
|
+
- `--deps`: Dependency audit (CVE scan of package.json / requirements.txt)
|
|
9
|
+
- `--secrets`: Secret detection scan only (fast, suitable for pre-commit hook)
|
|
10
|
+
- Flags composable: `--deps --secrets` runs both dependency audit and secret detection
|
|
11
|
+
|
|
12
|
+
## Step 1 — Activate Security Reviewer persona
|
|
13
|
+
|
|
14
|
+
Load `security-reviewer.md` persona immediately and completely.
|
|
15
|
+
This command runs entirely in security mode. Do not switch personas.
|
|
16
|
+
|
|
17
|
+
## Step 2 — Build scan scope
|
|
18
|
+
|
|
19
|
+
```bash
|
|
20
|
+
# Default: staged + unstaged changes
|
|
21
|
+
git diff HEAD --name-only
|
|
22
|
+
|
|
23
|
+
# With path argument
|
|
24
|
+
find [path] -name "*.ts" -o -name "*.js" -o -name "*.py"
|
|
25
|
+
|
|
26
|
+
# --deep: all source files
|
|
27
|
+
find src/ -type f \( -name "*.ts" -o -name "*.js" -o -name "*.py" \)
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
## Step 3 — OWASP Top 10 scan (always runs unless --secrets only)
|
|
31
|
+
|
|
32
|
+
For each file in scope, check all 10 OWASP categories:
|
|
33
|
+
|
|
34
|
+
### A01 — Broken Access Control
|
|
35
|
+
- Scan for: missing auth middleware, direct object references, path traversal
|
|
36
|
+
- Patterns to flag:
|
|
37
|
+
```
|
|
38
|
+
req.params.userId # Direct user ID from request — verify ownership check
|
|
39
|
+
fs.readFile(userInput) # Path traversal risk
|
|
40
|
+
WHERE id = ${id} # Direct injection without parameterisation
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
### A02 — Cryptographic Failures
|
|
44
|
+
- Scan for: weak algorithms, insecure transport, unencrypted sensitive data
|
|
45
|
+
- Patterns to flag:
|
|
46
|
+
```
|
|
47
|
+
md5(, sha1(, sha256(password # Weak password hashing
|
|
48
|
+
http:// # Non-HTTPS URLs in API calls
|
|
49
|
+
Math.random() # Cryptographically insecure random
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
### A03 — Injection
|
|
53
|
+
- Scan for: SQL, NoSQL, OS, LDAP injection
|
|
54
|
+
- Patterns to flag:
|
|
55
|
+
```
|
|
56
|
+
`SELECT * FROM users WHERE email = '${ # SQL injection
|
|
57
|
+
exec(, execSync(, child_process # OS command injection
|
|
58
|
+
eval(userInput # Code injection
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
### A04 — Insecure Design
|
|
62
|
+
- Scan for: missing rate limiting, no input validation, trust boundary issues
|
|
63
|
+
- Patterns to flag: endpoints without validation middleware, no rate limit decorators
|
|
64
|
+
|
|
65
|
+
### A05 — Security Misconfiguration
|
|
66
|
+
- Scan for: debug mode in production, default credentials, verbose errors
|
|
67
|
+
- Patterns to flag:
|
|
68
|
+
```
|
|
69
|
+
console.error(err) # Exposes stack traces to clients
|
|
70
|
+
NODE_ENV !== 'production' # Debug code paths
|
|
71
|
+
ALLOW_ALL, *, cors({origin: '*'}) # Overly permissive CORS
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
### A06 — Vulnerable Components
|
|
75
|
+
- Run: `npm audit --audit-level=moderate` or `pip-audit`
|
|
76
|
+
- Flag any HIGH or CRITICAL CVEs
|
|
77
|
+
|
|
78
|
+
### A07 — Authentication Failures
|
|
79
|
+
- Scan for: missing password complexity, no brute force protection, weak sessions
|
|
80
|
+
- Patterns to flag:
|
|
81
|
+
```
|
|
82
|
+
bcrypt.hashSync(pass, 1) # Cost factor too low
|
|
83
|
+
jwt.verify(token, '', { # Empty secret
|
|
84
|
+
session.destroy( # Verify redirect after destroy
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
### A08 — Software and Data Integrity Failures
|
|
88
|
+
- Check: no package-lock.json means no integrity guarantee
|
|
89
|
+
- Check: any `curl | sh` or `wget | bash` patterns
|
|
90
|
+
|
|
91
|
+
### A09 — Security Logging Failures
|
|
92
|
+
- Scan for: no logging on auth failures, admin actions not logged, PII in logs
|
|
93
|
+
- Patterns to flag:
|
|
94
|
+
```
|
|
95
|
+
user.email in any log statement
|
|
96
|
+
password in any log statement
|
|
97
|
+
catch(e) {} # Silent failure = no security log
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
### A10 — SSRF
|
|
101
|
+
- Scan for: server-side requests to user-controlled URLs
|
|
102
|
+
- Patterns to flag:
|
|
103
|
+
```
|
|
104
|
+
fetch(req., axios.get(req., axios.post(req., http.get(req.,
|
|
105
|
+
req.body.url, req.params.url, req.query.url, req.headers
|
|
106
|
+
```
|
|
107
|
+
|
|
108
|
+
## Step 4 — Secret detection (--secrets or always as part of default scan)
|
|
109
|
+
|
|
110
|
+
Pattern-based scan across all files in scope:
|
|
111
|
+
|
|
112
|
+
```bash
|
|
113
|
+
# High confidence patterns (always flag as CRITICAL)
|
|
114
|
+
grep -rn -E "(sk-[a-zA-Z0-9]{20,}|AKIA[A-Z0-9]{16}|ghp_[a-zA-Z0-9]{36})" .
|
|
115
|
+
|
|
116
|
+
# Credential assignment patterns (flag as HIGH)
|
|
117
|
+
grep -rn -E "(password|passwd|secret|api_key|apikey|access_token)\s*=\s*['\"][^'\"]{8,}" .
|
|
118
|
+
|
|
119
|
+
# Azure connection strings
|
|
120
|
+
grep -rn -E "DefaultEndpointsProtocol=https;AccountName=" .
|
|
121
|
+
|
|
122
|
+
# GCP service account keys
|
|
123
|
+
grep -rn -E "\"type\"\\s*:\\s*\"service_account\"" .
|
|
124
|
+
|
|
125
|
+
# PEM/Certificate content
|
|
126
|
+
grep -rn "-----BEGIN (RSA |EC |OPENSSH )?PRIVATE KEY-----" .
|
|
127
|
+
|
|
128
|
+
# Database URLs with credentials
|
|
129
|
+
grep -rn -E "postgres://[^:]+:[^@]+@|mysql://[^:]+:[^@]+@" .
|
|
130
|
+
```
|
|
131
|
+
|
|
132
|
+
Report each finding with:
|
|
133
|
+
- File and line number
|
|
134
|
+
- The matched pattern (redact the actual secret value: show first 4 chars + ***)
|
|
135
|
+
- Severity: CRITICAL if a real credential pattern, HIGH if credential-shaped pattern
|
|
136
|
+
Redaction applies to both console output and the report file.
|
|
137
|
+
|
|
138
|
+
## Step 5 — Dependency audit (--deps flag)
|
|
139
|
+
|
|
140
|
+
```bash
|
|
141
|
+
# Node.js projects
|
|
142
|
+
npm audit --json 2>/dev/null | node -e "
|
|
143
|
+
const data = JSON.parse(require('fs').readFileSync('/dev/stdin', 'utf8'));
|
|
144
|
+
const vulns = data.vulnerabilities || {};
|
|
145
|
+
Object.entries(vulns).forEach(([name, v]) => {
|
|
146
|
+
if (['high','critical'].includes(v.severity)) {
|
|
147
|
+
console.log(v.severity.toUpperCase() + ': ' + name + ' — ' + v.via[0]?.title);
|
|
148
|
+
}
|
|
149
|
+
});
|
|
150
|
+
"
|
|
151
|
+
|
|
152
|
+
# Python projects
|
|
153
|
+
pip-audit --format json 2>/dev/null
|
|
154
|
+
```
|
|
155
|
+
|
|
156
|
+
## Step 6 — Write security scan report
|
|
157
|
+
|
|
158
|
+
`.planning/SECURITY-SCAN-[timestamp].md`:
|
|
159
|
+
|
|
160
|
+
```markdown
|
|
161
|
+
# Security Scan Report
|
|
162
|
+
**Date:** [ISO-8601]
|
|
163
|
+
**Scope:** [what was scanned]
|
|
164
|
+
**Scanner:** MindForge Security Reviewer
|
|
165
|
+
|
|
166
|
+
## Executive Summary
|
|
167
|
+
[1-2 sentences: overall security posture, number of findings by severity]
|
|
168
|
+
|
|
169
|
+
## Critical Findings (fix immediately — block all merges)
|
|
170
|
+
[OWASP category] | [File:Line] | [Description] | [Remediation]
|
|
171
|
+
|
|
172
|
+
## High Findings (fix before next release)
|
|
173
|
+
...
|
|
174
|
+
|
|
175
|
+
## Medium Findings (fix in next sprint)
|
|
176
|
+
...
|
|
177
|
+
|
|
178
|
+
## Low Findings (backlog)
|
|
179
|
+
...
|
|
180
|
+
|
|
181
|
+
## Dependency Audit
|
|
182
|
+
| Package | Version | Severity | CVE | Fixed in |
|
|
183
|
+
|---|---|---|---|---|
|
|
184
|
+
|
|
185
|
+
## Secret Detection
|
|
186
|
+
| File | Pattern | Severity | Action |
|
|
187
|
+
|---|---|---|---|
|
|
188
|
+
|
|
189
|
+
## Verdict
|
|
190
|
+
✅ CLEAN — No critical or high findings
|
|
191
|
+
⚠️ ISSUES — [N] critical, [N] high findings require attention
|
|
192
|
+
```
|
|
193
|
+
|
|
194
|
+
## Important: scan report visibility
|
|
195
|
+
|
|
196
|
+
Security scan reports are written to `.planning/SECURITY-SCAN-[timestamp].md`.
|
|
197
|
+
|
|
198
|
+
**Private repository:** Keep reports committed — they are valuable for audit
|
|
199
|
+
history and team security review.
|
|
200
|
+
|
|
201
|
+
**Public repository:** Add `.planning/SECURITY-SCAN-*.md` to `.gitignore`
|
|
202
|
+
to avoid exposing vulnerability information to potential attackers.
|
|
203
|
+
|
|
204
|
+
MindForge does not make this decision for you — configure `.gitignore`
|
|
205
|
+
based on your repository's visibility.
|
|
206
|
+
|
|
207
|
+
## Step 7 — Write AUDIT entry
|
|
208
|
+
|
|
209
|
+
```json
|
|
210
|
+
{
|
|
211
|
+
"event": "security_scan_completed",
|
|
212
|
+
"scope": "[path or 'staged changes']",
|
|
213
|
+
"flags": ["--deps", "--secrets"],
|
|
214
|
+
"critical_findings": [N],
|
|
215
|
+
"high_findings": [N],
|
|
216
|
+
"secrets_detected": [N],
|
|
217
|
+
"vulnerable_deps": [N],
|
|
218
|
+
"report_path": ".planning/SECURITY-SCAN-[timestamp].md"
|
|
219
|
+
}
|
|
220
|
+
```
|
|
221
|
+
|
|
222
|
+
## Automatic blocking behaviour
|
|
223
|
+
If CRITICAL findings are detected: print a prominent warning:
|
|
224
|
+
```
|
|
225
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
226
|
+
🔴 CRITICAL SECURITY FINDINGS DETECTED
|
|
227
|
+
|
|
228
|
+
[N] critical issues must be fixed before any code is merged.
|
|
229
|
+
See: .planning/SECURITY-SCAN-[timestamp].md
|
|
230
|
+
|
|
231
|
+
Do NOT commit or deploy until these are resolved.
|
|
232
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
233
|
+
```
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
Create a release PR for a verified phase. Usage: /mindforge:ship [N]
|
|
2
|
+
|
|
3
|
+
## Pre-check
|
|
4
|
+
Read UAT.md for phase N. If status is not "All passed ✅": stop.
|
|
5
|
+
Tell the user: "Phase [N] has not been fully verified. Run /mindforge:verify-phase [N] first."
|
|
6
|
+
|
|
7
|
+
## Step 1 — Generate changelog entry
|
|
8
|
+
Read all SUMMARY files for phase N.
|
|
9
|
+
Read REQUIREMENTS.md for phase N items.
|
|
10
|
+
Generate a CHANGELOG.md entry following Keep a Changelog format:
|
|
11
|
+
|
|
12
|
+
```markdown
|
|
13
|
+
## [Unreleased] — Phase [N]: [Phase description]
|
|
14
|
+
|
|
15
|
+
### Added
|
|
16
|
+
- [New feature from this phase]
|
|
17
|
+
|
|
18
|
+
### Changed
|
|
19
|
+
- [Changed behaviour]
|
|
20
|
+
|
|
21
|
+
### Fixed
|
|
22
|
+
- [Bug fixes]
|
|
23
|
+
|
|
24
|
+
### Security
|
|
25
|
+
- [Security improvements]
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
Prepend this to CHANGELOG.md.
|
|
29
|
+
|
|
30
|
+
## Step 2 — Run final quality gates
|
|
31
|
+
Run all of the following and report results:
|
|
32
|
+
```bash
|
|
33
|
+
# Type checking
|
|
34
|
+
npx tsc --noEmit
|
|
35
|
+
|
|
36
|
+
# Linting
|
|
37
|
+
npx eslint . --ext .ts,.tsx --max-warnings 0
|
|
38
|
+
|
|
39
|
+
# Tests
|
|
40
|
+
npm test
|
|
41
|
+
|
|
42
|
+
# Security scan (if npm project)
|
|
43
|
+
npm audit --audit-level=high
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
If any gate fails: stop. Report the failures. Do not proceed to PR creation.
|
|
47
|
+
|
|
48
|
+
## Step 3 — Create PR description
|
|
49
|
+
Generate a complete PR description:
|
|
50
|
+
|
|
51
|
+
```markdown
|
|
52
|
+
## MindForge Phase [N] — [Phase description]
|
|
53
|
+
|
|
54
|
+
### Summary
|
|
55
|
+
[2-3 sentences describing what this phase delivered]
|
|
56
|
+
|
|
57
|
+
### Changes
|
|
58
|
+
[Bullet list of major changes from SUMMARY files]
|
|
59
|
+
|
|
60
|
+
### Requirements delivered
|
|
61
|
+
| FR ID | Description | Verified |
|
|
62
|
+
|-------|------------------------------|----------|
|
|
63
|
+
| FR-01 | ... | ✅ |
|
|
64
|
+
|
|
65
|
+
### Testing
|
|
66
|
+
- Unit tests: [pass/fail + coverage %]
|
|
67
|
+
- Integration tests: [pass/fail]
|
|
68
|
+
- UAT: Completed and signed off (see UAT.md)
|
|
69
|
+
|
|
70
|
+
### Security
|
|
71
|
+
- [ ] Security review completed (see SECURITY-REVIEW-N.md)
|
|
72
|
+
- [ ] No hardcoded secrets in diff
|
|
73
|
+
- [ ] All dependencies scanned for CVEs
|
|
74
|
+
|
|
75
|
+
### Checklist
|
|
76
|
+
- [x] CHANGELOG.md updated
|
|
77
|
+
- [x] All tests pass
|
|
78
|
+
- [x] No linter errors
|
|
79
|
+
- [x] UAT signed off
|
|
80
|
+
- [ ] Reviewed by: [assign]
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
## Step 4 — Commit and tag
|
|
84
|
+
```bash
|
|
85
|
+
git add CHANGELOG.md
|
|
86
|
+
git commit -m "docs(changelog): add Phase [N] release notes"
|
|
87
|
+
git push origin feat/mindforge-core-scaffold
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
Tell the user the PR description and instruct them to open the PR manually
|
|
91
|
+
(or provide the `gh pr create` command if GitHub CLI is available).
|
|
92
|
+
|
|
93
|
+
Tell the user:
|
|
94
|
+
"✅ Phase [N] ready to ship.
|
|
95
|
+
PR description generated above.
|
|
96
|
+
Open your PR, assign reviewers, and merge when approved."
|
|
97
|
+
|
|
98
|
+
## Step 5 — Update state
|
|
99
|
+
Update STATE.md to mark Phase [N] as shipped.
|
|
100
|
+
Update HANDOFF.json with next phase number.
|
|
@@ -0,0 +1,141 @@
|
|
|
1
|
+
# MindForge — Skills Command
|
|
2
|
+
# Usage: /mindforge:skills [subcommand] [args]
|
|
3
|
+
# Subcommands: list | add | update | validate | info | search
|
|
4
|
+
|
|
5
|
+
## Subcommand: list
|
|
6
|
+
`/mindforge:skills list`
|
|
7
|
+
|
|
8
|
+
Read MANIFEST.md. Display all registered skills in a formatted table
|
|
9
|
+
(include path for each skill):
|
|
10
|
+
|
|
11
|
+
```
|
|
12
|
+
MindForge Skills Registry
|
|
13
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
14
|
+
|
|
15
|
+
Tier 1 — Core Skills (10 installed)
|
|
16
|
+
────────────────────────────────────────────────────────────
|
|
17
|
+
✅ security-review v1.0.0 stable .mindforge/skills/security-review/SKILL.md
|
|
18
|
+
✅ code-quality v1.0.0 stable .mindforge/skills/code-quality/SKILL.md
|
|
19
|
+
✅ api-design v1.0.0 stable .mindforge/skills/api-design/SKILL.md
|
|
20
|
+
✅ testing-standards v1.0.0 stable .mindforge/skills/testing-standards/SKILL.md
|
|
21
|
+
✅ documentation v1.0.0 stable .mindforge/skills/documentation/SKILL.md
|
|
22
|
+
✅ performance v1.0.0 stable .mindforge/skills/performance/SKILL.md
|
|
23
|
+
✅ accessibility v1.0.0 stable .mindforge/skills/accessibility/SKILL.md
|
|
24
|
+
✅ data-privacy v1.0.0 stable .mindforge/skills/data-privacy/SKILL.md
|
|
25
|
+
✅ incident-response v1.0.0 stable .mindforge/skills/incident-response/SKILL.md
|
|
26
|
+
✅ database-patterns v1.0.0 stable .mindforge/skills/database-patterns/SKILL.md
|
|
27
|
+
|
|
28
|
+
Tier 2 — Org Skills (0 installed)
|
|
29
|
+
────────────────────────────────────────────────────────────
|
|
30
|
+
(none — run /mindforge:skills add to add org skills)
|
|
31
|
+
|
|
32
|
+
Tier 3 — Project Skills (0 installed)
|
|
33
|
+
────────────────────────────────────────────────────────────
|
|
34
|
+
(none)
|
|
35
|
+
|
|
36
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
37
|
+
Total: 10 skills | Run /mindforge:skills validate to check health
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
## Subcommand: info
|
|
41
|
+
`/mindforge:skills info [skill-name]`
|
|
42
|
+
|
|
43
|
+
Display detailed information about a specific skill:
|
|
44
|
+
|
|
45
|
+
```
|
|
46
|
+
Skill: security-review
|
|
47
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
48
|
+
Version : 1.0.0
|
|
49
|
+
Status : stable
|
|
50
|
+
Tier : 1 (Core)
|
|
51
|
+
Min MindForge: 0.1.0
|
|
52
|
+
Path : .mindforge/skills/security-review/SKILL.md
|
|
53
|
+
|
|
54
|
+
Triggers (25):
|
|
55
|
+
auth, authentication, authorisation, authorization, login,
|
|
56
|
+
logout, password, token, JWT, session, cookie, OAuth,
|
|
57
|
+
payment, billing, stripe, PII, GDPR, personal data,
|
|
58
|
+
upload, file upload, credentials, API key, secret, env,
|
|
59
|
+
environment variable, encryption, hashing, bcrypt, argon2
|
|
60
|
+
|
|
61
|
+
Changelog:
|
|
62
|
+
1.0.0 — Initial stable release
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
## Subcommand: search
|
|
66
|
+
`/mindforge:skills search [keyword]`
|
|
67
|
+
|
|
68
|
+
Find which skills would activate for a given keyword:
|
|
69
|
+
|
|
70
|
+
```
|
|
71
|
+
/mindforge:skills search "database query"
|
|
72
|
+
|
|
73
|
+
Matching skills for "database query":
|
|
74
|
+
────────────────────────────────────────────────────────────
|
|
75
|
+
database-patterns v1.0.0 [tier 1] trigger: "database", "query"
|
|
76
|
+
performance v1.0.0 [tier 1] trigger: "query time"
|
|
77
|
+
|
|
78
|
+
These 2 skills would be automatically loaded for a task
|
|
79
|
+
containing "database query" in its description.
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
## Subcommand: validate
|
|
83
|
+
`/mindforge:skills validate`
|
|
84
|
+
|
|
85
|
+
Run a health check on all installed skills:
|
|
86
|
+
|
|
87
|
+
```
|
|
88
|
+
Validating skills...
|
|
89
|
+
|
|
90
|
+
✅ security-review — frontmatter valid, file readable, triggers: 29
|
|
91
|
+
✅ code-quality — frontmatter valid, file readable, triggers: 14
|
|
92
|
+
✅ performance — frontmatter valid, file readable, triggers: 31
|
|
93
|
+
⚠️ [org-skill-name] — frontmatter valid but missing 'version' field
|
|
94
|
+
❌ [missing-skill] — listed in MANIFEST.md but file not found
|
|
95
|
+
|
|
96
|
+
Issues found: 2
|
|
97
|
+
Run /mindforge:skills add to fix missing skills.
|
|
98
|
+
Fix frontmatter issues manually in the SKILL.md file.
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
Validation checks:
|
|
102
|
+
1. Every manifest entry has a corresponding SKILL.md file
|
|
103
|
+
2. Every SKILL.md has: `name`, `version`, `status`, `triggers` in frontmatter
|
|
104
|
+
3. Every SKILL.md has a self-check or checklist section
|
|
105
|
+
4. All versions are valid semver strings
|
|
106
|
+
5. No two skills at the same tier share the same trigger keyword (flag as ⚠️)
|
|
107
|
+
6. Every skill file is readable (not empty, not corrupted)
|
|
108
|
+
|
|
109
|
+
## Subcommand: add
|
|
110
|
+
`/mindforge:skills add [path-to-skill-dir]`
|
|
111
|
+
|
|
112
|
+
Register a new skill in the manifest:
|
|
113
|
+
|
|
114
|
+
1. Read the SKILL.md in the provided path
|
|
115
|
+
2. Validate the frontmatter (all required fields present)
|
|
116
|
+
3. Check for trigger keyword conflicts with existing skills
|
|
117
|
+
4. Ask the user: "Which tier should this skill be registered as? (2=Org / 3=Project)"
|
|
118
|
+
5. Show the exact MANIFEST.md entry that will be written and ask for confirmation
|
|
119
|
+
6. Add the entry to MANIFEST.md in the correct section
|
|
120
|
+
7. Run `/mindforge:skills validate` to confirm registration is clean
|
|
121
|
+
8. Commit: `feat(skills): register [skill-name] v[version] as tier [N] skill`
|
|
122
|
+
|
|
123
|
+
## Subcommand: update
|
|
124
|
+
`/mindforge:skills update [skill-name]`
|
|
125
|
+
|
|
126
|
+
Update a skill to a newer version:
|
|
127
|
+
|
|
128
|
+
1. Read current version from MANIFEST.md
|
|
129
|
+
2. Check the skill's changelog in SKILL.md for available updates
|
|
130
|
+
3. If MAJOR version change: show breaking changes, require confirmation
|
|
131
|
+
4. If MINOR or PATCH: update automatically
|
|
132
|
+
5. Update MANIFEST.md version entry
|
|
133
|
+
6. Run `/mindforge:skills validate` after update
|
|
134
|
+
7. Run `node tests/skills-platform.test.js` after update
|
|
135
|
+
8. Commit: `chore(skills): update [name] v[old] → v[new]`
|
|
136
|
+
|
|
137
|
+
## Error handling
|
|
138
|
+
- If MANIFEST.md does not exist: offer to create it with current skills
|
|
139
|
+
- If a skill name is not found: suggest similar names (fuzzy match)
|
|
140
|
+
- If validation finds critical errors: block any phase execution until fixed
|
|
141
|
+
(A skills validation failure is a BLOCKING issue)
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
# MindForge — Status Command
|
|
2
|
+
# Usage: /mindforge:status
|
|
3
|
+
|
|
4
|
+
Display a rich dashboard of the current project state.
|
|
5
|
+
Pull data from STATE.md, AUDIT.jsonl, REQUIREMENTS.md, and the phases directory.
|
|
6
|
+
|
|
7
|
+
## Dashboard sections
|
|
8
|
+
|
|
9
|
+
### Section 1 — Project header
|
|
10
|
+
```
|
|
11
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
12
|
+
⚡ MindForge Status — [Project Name]
|
|
13
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
14
|
+
Last updated : [STATE.md last updated timestamp]
|
|
15
|
+
Current phase: Phase [N] — [phase description]
|
|
16
|
+
Status : [status from STATE.md]
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
### Section 2 — Phase progress
|
|
20
|
+
```
|
|
21
|
+
Phase Progress
|
|
22
|
+
───────────────────────────────────────────────────────
|
|
23
|
+
Phase 1 [████████████████████] 100% — Complete ✅
|
|
24
|
+
Phase 2 [████████░░░░░░░░░░░░] 40% — In progress
|
|
25
|
+
Phase 3 [░░░░░░░░░░░░░░░░░░░░] 0% — Not started
|
|
26
|
+
Phase 4 [░░░░░░░░░░░░░░░░░░░░] 0% — Not started
|
|
27
|
+
```
|
|
28
|
+
Calculate percentage from: tasks with SUMMARY files / total tasks in phase.
|
|
29
|
+
Count ONLY SUMMARY files that contain `Status: Completed ✅` (or `Status` + `Completed`).
|
|
30
|
+
Do not count failed tasks as progress.
|
|
31
|
+
If VERIFICATION.md is missing for a phase: label it "In progress" not "0% verified".
|
|
32
|
+
|
|
33
|
+
### Section 3 — Requirements coverage
|
|
34
|
+
Read REQUIREMENTS.md and count:
|
|
35
|
+
- Total v1 requirements
|
|
36
|
+
- Requirements with a passing test (from VERIFICATION.md files)
|
|
37
|
+
- Requirements implemented but untested
|
|
38
|
+
- Requirements not yet started
|
|
39
|
+
|
|
40
|
+
```
|
|
41
|
+
Requirements (v1)
|
|
42
|
+
───────────────────────────────────────────────────────
|
|
43
|
+
Total : [N]
|
|
44
|
+
✅ Done + tested : [N]
|
|
45
|
+
⚠️ Done, no test : [N]
|
|
46
|
+
🔴 Not started : [N]
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
### Section 4 — Recent activity (from AUDIT.jsonl)
|
|
50
|
+
Read the last 10 entries from AUDIT.jsonl and display:
|
|
51
|
+
```
|
|
52
|
+
Recent Activity
|
|
53
|
+
───────────────────────────────────────────────────────
|
|
54
|
+
[timestamp] task_completed Plan 03: User API endpoints ✅
|
|
55
|
+
[timestamp] task_completed Plan 02: Product model ✅
|
|
56
|
+
[timestamp] task_started Plan 03: User API endpoints
|
|
57
|
+
[timestamp] task_completed Plan 01: User model ✅
|
|
58
|
+
[timestamp] context_compaction Phase 2, Plan 03 (72% context)
|
|
59
|
+
```
|
|
60
|
+
If AUDIT.jsonl is empty or missing, display:
|
|
61
|
+
```
|
|
62
|
+
Recent Activity
|
|
63
|
+
───────────────────────────────────────────────────────
|
|
64
|
+
No activity logged yet. Activity will appear here
|
|
65
|
+
after running /mindforge:execute-phase.
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
### Section 5 — Open issues
|
|
69
|
+
Check for:
|
|
70
|
+
- Any open SECURITY-REVIEW files with CRITICAL or HIGH findings
|
|
71
|
+
- Any BUGS.md files with open issues
|
|
72
|
+
- Any failed tasks in WAVE-REPORT files
|
|
73
|
+
- Any blockers in STATE.md
|
|
74
|
+
|
|
75
|
+
```
|
|
76
|
+
Open Issues
|
|
77
|
+
───────────────────────────────────────────────────────
|
|
78
|
+
🔴 CRITICAL: [if any — from SECURITY-REVIEW]
|
|
79
|
+
🟠 HIGH: [if any]
|
|
80
|
+
✅ No open issues
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
### Section 6 — Next action
|
|
84
|
+
```
|
|
85
|
+
Next Action
|
|
86
|
+
───────────────────────────────────────────────────────
|
|
87
|
+
[What STATE.md says the next action is]
|
|
88
|
+
Run: /mindforge:next
|
|
89
|
+
to auto-execute the next step.
|
|
90
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
## Data sources (in priority order)
|
|
94
|
+
1. STATE.md — authoritative for current status
|
|
95
|
+
2. AUDIT.jsonl — authoritative for history
|
|
96
|
+
3. REQUIREMENTS.md — authoritative for scope
|
|
97
|
+
4. VERIFICATION.md files — authoritative for test coverage
|
|
98
|
+
5. WAVE-REPORT files — authoritative for execution history
|
|
99
|
+
6. HANDOFF.json — authoritative for session state
|
|
100
|
+
|
|
101
|
+
## Performance notes
|
|
102
|
+
- For recent activity, read only the last 500 bytes of AUDIT.jsonl:
|
|
103
|
+
`tail -c 500 .planning/AUDIT.jsonl | [parse last complete JSON objects]`
|
|
104
|
+
- For requirement counts, count lines starting with `| FR-` instead of parsing the whole file.
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
Publish approved planning artifacts to Confluence. Usage:
|
|
2
|
+
`/mindforge:sync-confluence [--architecture] [--phase N] [--milestone name]`
|
|
3
|
+
|
|
4
|
+
## Behaviour
|
|
5
|
+
- verify Confluence availability through `connection-manager.md`
|
|
6
|
+
- publish idempotently by existing page title or page ID
|
|
7
|
+
- never publish secrets, raw approval notes, or raw audit logs
|
|
8
|
+
- log success, skip, or failure to AUDIT
|
|
9
|
+
|
|
10
|
+
Publishing failures are non-fatal and create a pending manual action in
|
|
11
|
+
`STATE.md`.
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
Synchronise MindForge phase and plan metadata to Jira. Usage:
|
|
2
|
+
`/mindforge:sync-jira [--phase N] [--plan M]`
|
|
3
|
+
|
|
4
|
+
## Behaviour
|
|
5
|
+
- verify Jira availability through `connection-manager.md`
|
|
6
|
+
- create or update Epic and Story mappings in `.planning/jira-sync.json`
|
|
7
|
+
- use dynamic transition lookup, never hardcoded IDs
|
|
8
|
+
- preserve manual Jira edits
|
|
9
|
+
- log all actions to AUDIT
|
|
10
|
+
|
|
11
|
+
Integration failures are non-fatal and should be written to `STATE.md` for
|
|
12
|
+
manual retry.
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
# MindForge — Token Usage Command
|
|
2
|
+
# Usage: /mindforge:tokens [--phase N] [--session ID] [--window short|medium|long] [--optimise]
|
|
3
|
+
|
|
4
|
+
## Purpose
|
|
5
|
+
Display token consumption profile and efficiency analysis.
|
|
6
|
+
Helps identify where tokens are being spent and how to reduce waste.
|
|
7
|
+
|
|
8
|
+
## Default output (no flags — last 5 sessions)
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
# MindForge — Update Command
|
|
2
|
+
# Usage: /mindforge:update [--apply] [--force] [--check] [--skip-changelog]
|
|
3
|
+
|
|
4
|
+
## Purpose
|
|
5
|
+
Check for and apply MindForge framework updates in a safe, scope-preserving way.
|
|
6
|
+
|
|
7
|
+
## Execution flow
|
|
8
|
+
|
|
9
|
+
### 1. Version check
|
|
10
|
+
Execute `bin/updater/self-update.js` `checkAndUpdate()`.
|
|
11
|
+
Always show: current version, latest version, update type (major/minor/patch).
|
|
12
|
+
|
|
13
|
+
### 2. Changelog display (unless --skip-changelog)
|
|
14
|
+
Fetch and display the relevant CHANGELOG.md section.
|
|
15
|
+
For major updates: prefix with ⚠️ BREAKING CHANGES notice.
|
|
16
|
+
Limit display to 3,000 characters — link to full CHANGELOG for the rest.
|
|
17
|
+
|
|
18
|
+
### 3. Confirmation gate (unless --apply)
|
|
19
|
+
Without --apply: show update info, stop. Do not modify any files.
|
|
20
|
+
Message: "To apply this update: /mindforge:update --apply"
|
|
21
|
+
|
|
22
|
+
### 4. Apply (with --apply)
|
|
23
|
+
a. Detect original install scope (local vs global, claude vs antigravity)
|
|
24
|
+
b. Read schema_version from HANDOFF.json (captures current version BEFORE update)
|
|
25
|
+
c. Run `npx mindforge-cc@[latest] --[runtime] --[scope]`
|
|
26
|
+
d. Run migration: `node bin/migrations/migrate.js` with captured schema_version
|
|
27
|
+
e. Run /mindforge:health to verify update succeeded
|
|
28
|
+
|
|
29
|
+
### 5. Post-update health check
|
|
30
|
+
If health errors: surface them immediately with specific fix instructions.
|
|
31
|
+
Common post-update issue: CLAUDE.md and .agent/CLAUDE.md drifted → auto-repair.
|
|
32
|
+
|
|
33
|
+
## Error scenarios and recovery
|
|
34
|
+
|
|
35
|
+
| Error | Recovery |
|
|
36
|
+
|---|---|
|
|
37
|
+
| npm registry unreachable | Message: "Check internet. Manual: npm info mindforge-cc version" |
|
|
38
|
+
| Update download fails | Retry once, then suggest manual: `npx mindforge-cc@latest` |
|
|
39
|
+
| Migration fails | Restored from backup automatically. Run /mindforge:migrate manually. |
|
|
40
|
+
| Install scope detection fails | Prompt user: "Is your install global or local?" |
|
|
41
|
+
|
|
42
|
+
## AUDIT entry
|