opencode-skills-collection 3.0.46 → 3.0.48
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/bundled-skills/.antigravity-install-manifest.json +15 -1
- package/bundled-skills/2slides-ppt-generator/SKILL.md +1 -1
- package/bundled-skills/2slides-ppt-generator/scripts/create_pdf_slides.py +2 -1
- package/bundled-skills/2slides-ppt-generator/scripts/generate_narration.py +2 -1
- package/bundled-skills/2slides-ppt-generator/scripts/generate_slides.py +13 -7
- package/bundled-skills/accint-solve/SKILL.md +205 -0
- package/bundled-skills/android-cli/SKILL.md +239 -0
- package/bundled-skills/android-cli/references/interact.md +83 -0
- package/bundled-skills/android-cli/references/journeys.md +105 -0
- package/bundled-skills/android-dev/references/hybrid.md +7 -4
- package/bundled-skills/android-dev/references/react-native.md +5 -2
- package/bundled-skills/atlas-contract/SKILL.md +4 -4
- package/bundled-skills/atlas-ledger/SKILL.md +10 -7
- package/bundled-skills/bun-development/SKILL.md +1 -1
- package/bundled-skills/cloud-penetration-testing/SKILL.md +1 -1
- package/bundled-skills/codebase-to-wordpress-converter/SKILL.md +1 -0
- package/bundled-skills/codex-fable5/SKILL.md +154 -0
- package/bundled-skills/docs/integrations/jetski-cortex.md +3 -3
- package/bundled-skills/docs/integrations/jetski-gemini-loader/README.md +1 -1
- package/bundled-skills/docs/maintainers/repo-growth-seo.md +3 -3
- package/bundled-skills/docs/maintainers/skills-update-guide.md +1 -1
- package/bundled-skills/docs/users/bundles.md +1 -1
- package/bundled-skills/docs/users/claude-code-skills.md +1 -1
- package/bundled-skills/docs/users/gemini-cli-skills.md +1 -1
- package/bundled-skills/docs/users/getting-started.md +1 -1
- package/bundled-skills/docs/users/kiro-integration.md +1 -1
- package/bundled-skills/docs/users/usage.md +4 -4
- package/bundled-skills/docs/users/visual-guide.md +4 -4
- package/bundled-skills/dos-verify-done-claims/SKILL.md +173 -0
- package/bundled-skills/ecl-harness-engineer/LICENSE +21 -0
- package/bundled-skills/ecl-harness-engineer/SKILL.md +714 -0
- package/bundled-skills/ecl-harness-engineer/agents/analyzer.md +119 -0
- package/bundled-skills/ecl-harness-engineer/agents/auditor.md +212 -0
- package/bundled-skills/ecl-harness-engineer/agents/creator-config.md +343 -0
- package/bundled-skills/ecl-harness-engineer/agents/creator-docs.md +201 -0
- package/bundled-skills/ecl-harness-engineer/agents/creator-linters.md +123 -0
- package/bundled-skills/ecl-harness-engineer/references/adapters/adapter-schema.md +204 -0
- package/bundled-skills/ecl-harness-engineer/references/adapters/generic.md +156 -0
- package/bundled-skills/ecl-harness-engineer/references/adapters/go.md +212 -0
- package/bundled-skills/ecl-harness-engineer/references/adapters/java.md +205 -0
- package/bundled-skills/ecl-harness-engineer/references/adapters/python.md +225 -0
- package/bundled-skills/ecl-harness-engineer/references/adapters/rust.md +220 -0
- package/bundled-skills/ecl-harness-engineer/references/adapters/typescript.md +245 -0
- package/bundled-skills/ecl-harness-engineer/references/architecture-diagrams.md +420 -0
- package/bundled-skills/ecl-harness-engineer/references/audit-templates.md +649 -0
- package/bundled-skills/ecl-harness-engineer/references/capability-registry.md +485 -0
- package/bundled-skills/ecl-harness-engineer/references/darwin-eval-prompts.md +373 -0
- package/bundled-skills/ecl-harness-engineer/references/documentation-templates.md +741 -0
- package/bundled-skills/ecl-harness-engineer/references/durability-patterns.md +423 -0
- package/bundled-skills/ecl-harness-engineer/references/ecl-harness.md +1431 -0
- package/bundled-skills/ecl-harness-engineer/references/environment-config-guide.md +534 -0
- package/bundled-skills/ecl-harness-engineer/references/environment-detection-guide.md +751 -0
- package/bundled-skills/ecl-harness-engineer/references/eval-templates.md +377 -0
- package/bundled-skills/ecl-harness-engineer/references/gc-templates.md +798 -0
- package/bundled-skills/ecl-harness-engineer/references/greenfield-templates.md +1385 -0
- package/bundled-skills/ecl-harness-engineer/references/linter-templates.md +448 -0
- package/bundled-skills/ecl-harness-engineer/references/observability-templates.md +315 -0
- package/bundled-skills/efficient-web-research/SKILL.md +320 -0
- package/bundled-skills/environment-setup-guide/SKILL.md +2 -2
- package/bundled-skills/evolution/SKILL.md +1 -1
- package/bundled-skills/gitops-workflow/SKILL.md +1 -1
- package/bundled-skills/linkerd-patterns/SKILL.md +1 -1
- package/bundled-skills/loki-mode/examples/todo-app-generated/frontend/package-lock.json +504 -1317
- package/bundled-skills/loki-mode/examples/todo-app-generated/frontend/package.json +2 -2
- package/bundled-skills/lovable-cleanup/SKILL.md +416 -0
- package/bundled-skills/monopoly/SKILL.md +397 -0
- package/bundled-skills/monopoly/patterns/SKILL.md +331 -0
- package/bundled-skills/monopoly/scale-benchmarks/SKILL.md +174 -0
- package/bundled-skills/monopoly/security-checklist/SKILL.md +69 -0
- package/bundled-skills/monopoly/tech-matrix/SKILL.md +268 -0
- package/bundled-skills/pagespeed-enhancer/SKILL.md +579 -0
- package/bundled-skills/polis-protocol/SKILL.md +6 -3
- package/bundled-skills/sharp-coder/SKILL.md +131 -0
- package/bundled-skills/unship/SKILL.md +11 -5
- package/bundled-skills/uv-package-manager/resources/implementation-playbook.md +1 -1
- package/bundled-skills/varlock/SKILL.md +2 -2
- package/package.json +1 -1
- package/skills_index.json +314 -4
|
@@ -0,0 +1,220 @@
|
|
|
1
|
+
---
|
|
2
|
+
adapter:
|
|
3
|
+
language: rust
|
|
4
|
+
display_name: "Rust"
|
|
5
|
+
version: "1.0"
|
|
6
|
+
|
|
7
|
+
detection:
|
|
8
|
+
files: [Cargo.toml, Cargo.lock]
|
|
9
|
+
content_patterns:
|
|
10
|
+
- file: "Cargo.toml"
|
|
11
|
+
pattern: '\\[package\\]'
|
|
12
|
+
confidence: 0.95
|
|
13
|
+
|
|
14
|
+
commands:
|
|
15
|
+
build: "cargo build"
|
|
16
|
+
test: "cargo test"
|
|
17
|
+
lint: "cargo clippy -- -D warnings"
|
|
18
|
+
lint_arch: null # Rust module system enforces architecture naturally
|
|
19
|
+
format: "cargo fmt"
|
|
20
|
+
start: "cargo run"
|
|
21
|
+
dev: "cargo watch -x run"
|
|
22
|
+
|
|
23
|
+
package_manager:
|
|
24
|
+
detection: [] # Cargo is built-in
|
|
25
|
+
default: "cargo"
|
|
26
|
+
install_command: "cargo build"
|
|
27
|
+
|
|
28
|
+
route_detection:
|
|
29
|
+
server_indicators:
|
|
30
|
+
- pattern: 'use actix_web|actix_web::'
|
|
31
|
+
description: "Actix-web framework"
|
|
32
|
+
frameworks: ["actix-web"]
|
|
33
|
+
- pattern: 'use axum|axum::'
|
|
34
|
+
description: "Axum web framework"
|
|
35
|
+
frameworks: ["axum"]
|
|
36
|
+
- pattern: 'use rocket|#\[rocket::main\]'
|
|
37
|
+
description: "Rocket web framework"
|
|
38
|
+
frameworks: ["rocket"]
|
|
39
|
+
- pattern: 'use warp|warp::'
|
|
40
|
+
description: "Warp web framework"
|
|
41
|
+
frameworks: ["warp"]
|
|
42
|
+
- pattern: 'use hyper|hyper::'
|
|
43
|
+
description: "Hyper HTTP library"
|
|
44
|
+
frameworks: ["hyper"]
|
|
45
|
+
- pattern: 'use tide|tide::'
|
|
46
|
+
description: "Tide web framework"
|
|
47
|
+
frameworks: ["tide"]
|
|
48
|
+
|
|
49
|
+
cli_indicators:
|
|
50
|
+
- pattern: 'use clap|clap::'
|
|
51
|
+
description: "Clap CLI framework"
|
|
52
|
+
frameworks: ["clap"]
|
|
53
|
+
- pattern: 'use structopt|structopt::'
|
|
54
|
+
description: "StructOpt CLI (legacy clap)"
|
|
55
|
+
frameworks: ["structopt"]
|
|
56
|
+
- pattern: 'std::env::args'
|
|
57
|
+
description: "Standard library args parsing"
|
|
58
|
+
frameworks: ["stdlib"]
|
|
59
|
+
|
|
60
|
+
frontend_indicators:
|
|
61
|
+
- pattern: 'use leptos|leptos::'
|
|
62
|
+
description: "Leptos WASM framework"
|
|
63
|
+
frameworks: ["leptos"]
|
|
64
|
+
- pattern: 'use yew|yew::'
|
|
65
|
+
description: "Yew WASM framework"
|
|
66
|
+
frameworks: ["yew"]
|
|
67
|
+
- pattern: 'use dioxus|dioxus::'
|
|
68
|
+
description: "Dioxus UI framework"
|
|
69
|
+
frameworks: ["dioxus"]
|
|
70
|
+
|
|
71
|
+
patterns:
|
|
72
|
+
# Actix-web
|
|
73
|
+
- type: route
|
|
74
|
+
regex: '#\[(?:web::)?(get|post|put|delete|patch)\s*\(\s*"([^"]+)"'
|
|
75
|
+
groups: [method, path]
|
|
76
|
+
frameworks: ["actix-web"]
|
|
77
|
+
# Axum
|
|
78
|
+
- type: route
|
|
79
|
+
regex: '\.(get|post|put|delete|patch)\s*\(\s*"([^"]+)"'
|
|
80
|
+
groups: [method, path]
|
|
81
|
+
frameworks: ["axum"]
|
|
82
|
+
# Rocket
|
|
83
|
+
- type: route
|
|
84
|
+
regex: '#\[(get|post|put|delete|patch)\s*\(\s*"([^"]+)"'
|
|
85
|
+
groups: [method, path]
|
|
86
|
+
frameworks: ["rocket"]
|
|
87
|
+
# Clap derive
|
|
88
|
+
- type: command
|
|
89
|
+
regex: '#\[command\s*\(.*name\s*=\s*"([^"]+)"'
|
|
90
|
+
groups: [command_name]
|
|
91
|
+
frameworks: ["clap"]
|
|
92
|
+
# Clap builder
|
|
93
|
+
- type: command
|
|
94
|
+
regex: 'Command::new\s*\(\s*"([^"]+)"'
|
|
95
|
+
groups: [command_name]
|
|
96
|
+
frameworks: ["clap"]
|
|
97
|
+
|
|
98
|
+
import_analysis:
|
|
99
|
+
list_packages: "cargo metadata --format-version 1"
|
|
100
|
+
import_pattern: "use\\s+([\\w:]+)"
|
|
101
|
+
source_extensions: [".rs"]
|
|
102
|
+
module_root_file: "Cargo.toml"
|
|
103
|
+
|
|
104
|
+
layer_conventions:
|
|
105
|
+
patterns:
|
|
106
|
+
- layer: 0
|
|
107
|
+
paths: ["src/models", "src/types", "src/domain"]
|
|
108
|
+
description: "Domain types and models"
|
|
109
|
+
- layer: 1
|
|
110
|
+
paths: ["src/utils", "src/common", "src/lib.rs"]
|
|
111
|
+
description: "Shared utilities"
|
|
112
|
+
- layer: 2
|
|
113
|
+
paths: ["src/services", "src/core", "src/repository"]
|
|
114
|
+
description: "Business logic"
|
|
115
|
+
- layer: 3
|
|
116
|
+
paths: ["src/handlers", "src/routes", "src/api"]
|
|
117
|
+
description: "HTTP/API handlers"
|
|
118
|
+
- layer: 4
|
|
119
|
+
paths: ["src/main.rs", "src/bin"]
|
|
120
|
+
description: "Entry points"
|
|
121
|
+
|
|
122
|
+
dependency_detection:
|
|
123
|
+
manifest_file: "Cargo.toml"
|
|
124
|
+
databases:
|
|
125
|
+
- pattern: 'sqlx.*postgres|tokio-postgres|diesel.*postgres'
|
|
126
|
+
type: "postgres"
|
|
127
|
+
default_port: 5432
|
|
128
|
+
- pattern: 'sqlx.*mysql|diesel.*mysql'
|
|
129
|
+
type: "mysql"
|
|
130
|
+
default_port: 3306
|
|
131
|
+
- pattern: 'mongodb'
|
|
132
|
+
type: "mongodb"
|
|
133
|
+
default_port: 27017
|
|
134
|
+
- pattern: 'redis|deadpool-redis'
|
|
135
|
+
type: "redis"
|
|
136
|
+
default_port: 6379
|
|
137
|
+
- pattern: 'rusqlite|sqlx.*sqlite'
|
|
138
|
+
type: "sqlite"
|
|
139
|
+
default_port: 0
|
|
140
|
+
services:
|
|
141
|
+
- pattern: 'rdkafka|kafka'
|
|
142
|
+
type: "kafka"
|
|
143
|
+
default_port: 9092
|
|
144
|
+
- pattern: 'lapin|amqp'
|
|
145
|
+
type: "rabbitmq"
|
|
146
|
+
default_port: 5672
|
|
147
|
+
- pattern: 'elasticsearch'
|
|
148
|
+
type: "elasticsearch"
|
|
149
|
+
default_port: 9200
|
|
150
|
+
env_var_patterns:
|
|
151
|
+
- pattern: 'std::env::var\(\s*"([^"]+)"'
|
|
152
|
+
- pattern: 'env::var\(\s*"([^"]+)"'
|
|
153
|
+
- pattern: 'dotenv::var\(\s*"([^"]+)"'
|
|
154
|
+
|
|
155
|
+
linter:
|
|
156
|
+
template_section: "rust-linter"
|
|
157
|
+
script_extension: ".rs"
|
|
158
|
+
run_command: "cargo clippy"
|
|
159
|
+
|
|
160
|
+
naming:
|
|
161
|
+
file_pattern: "^[a-z][a-z0-9_]*\\.rs$"
|
|
162
|
+
test_pattern: "^[a-z][a-z0-9_]*\\.rs$" # Tests are inline in Rust
|
|
163
|
+
directory_style: "snake_case"
|
|
164
|
+
|
|
165
|
+
ci:
|
|
166
|
+
github_actions:
|
|
167
|
+
image: null
|
|
168
|
+
setup_steps:
|
|
169
|
+
- "uses: dtolnay/rust-toolchain@stable\n with:\n components: clippy, rustfmt"
|
|
170
|
+
cache_paths: ["~/.cargo/registry", "~/.cargo/git", "target"]
|
|
171
|
+
---
|
|
172
|
+
|
|
173
|
+
# Rust Adapter
|
|
174
|
+
|
|
175
|
+
## Architecture Note
|
|
176
|
+
|
|
177
|
+
Rust's module system (`mod`, `pub`, `pub(crate)`) naturally enforces encapsulation.
|
|
178
|
+
The `lint_arch` command is `null` because Rust's compiler already prevents many
|
|
179
|
+
dependency violations at compile time. However, a custom architectural linter can
|
|
180
|
+
still be valuable for enforcing higher-level layer boundaries.
|
|
181
|
+
|
|
182
|
+
## Server Start Command Inference
|
|
183
|
+
|
|
184
|
+
1. Existing `harness/config/environment.json` startup command, if present
|
|
185
|
+
2. `Cargo.toml` has `[[bin]]` section → `cargo run --bin <name>`
|
|
186
|
+
3. Default → `cargo run`
|
|
187
|
+
|
|
188
|
+
For release builds: `cargo build --release && ./target/release/<name>`
|
|
189
|
+
|
|
190
|
+
## Framework-Specific Notes
|
|
191
|
+
|
|
192
|
+
### Axum
|
|
193
|
+
- Router-based: `Router::new().route("/path", get(handler))`
|
|
194
|
+
- Extractors for request parsing: `Json<T>`, `Path<T>`, `Query<T>`
|
|
195
|
+
- State sharing via `Extension` or `State`
|
|
196
|
+
- Default: runs on `0.0.0.0:3000`
|
|
197
|
+
|
|
198
|
+
### Actix-web
|
|
199
|
+
- Attribute macros: `#[get("/path")]`, `#[post("/path")]`
|
|
200
|
+
- App factory pattern: `App::new().service(handler)`
|
|
201
|
+
- Default: `HttpServer::new(...).bind("127.0.0.1:8080")`
|
|
202
|
+
|
|
203
|
+
### Rocket
|
|
204
|
+
- Attribute macros: `#[get("/path")]`, `#[post("/path")]`
|
|
205
|
+
- Fairings for middleware
|
|
206
|
+
- Config via `Rocket.toml`
|
|
207
|
+
|
|
208
|
+
## Testing Patterns
|
|
209
|
+
|
|
210
|
+
- Unit tests: inline `#[cfg(test)] mod tests { ... }` in same file
|
|
211
|
+
- Integration tests: `tests/` directory at crate root
|
|
212
|
+
- `cargo test` runs both
|
|
213
|
+
- Useful flags: `cargo test -- --nocapture` (show println output)
|
|
214
|
+
|
|
215
|
+
## Workspace Support
|
|
216
|
+
|
|
217
|
+
If `[workspace]` in root `Cargo.toml`:
|
|
218
|
+
- Each member crate may have its own layer conventions
|
|
219
|
+
- Build: `cargo build --workspace`
|
|
220
|
+
- Test: `cargo test --workspace`
|
|
@@ -0,0 +1,245 @@
|
|
|
1
|
+
---
|
|
2
|
+
adapter:
|
|
3
|
+
language: typescript
|
|
4
|
+
display_name: "TypeScript / JavaScript"
|
|
5
|
+
version: "1.0"
|
|
6
|
+
|
|
7
|
+
detection:
|
|
8
|
+
files: [package.json, tsconfig.json]
|
|
9
|
+
content_patterns:
|
|
10
|
+
- file: "package.json"
|
|
11
|
+
pattern: '"(typescript|@types/node)"'
|
|
12
|
+
confidence: 0.90
|
|
13
|
+
|
|
14
|
+
commands:
|
|
15
|
+
build: "{pkg_manager} run build"
|
|
16
|
+
test: "{pkg_manager} test"
|
|
17
|
+
lint: "{pkg_manager} run lint"
|
|
18
|
+
lint_arch: "{pkg_manager} run lint:arch"
|
|
19
|
+
format: "{pkg_manager} run format"
|
|
20
|
+
start: "{pkg_manager} start"
|
|
21
|
+
dev: "{pkg_manager} run dev"
|
|
22
|
+
|
|
23
|
+
package_manager:
|
|
24
|
+
detection:
|
|
25
|
+
- lockfile: "pnpm-lock.yaml"
|
|
26
|
+
manager: "pnpm"
|
|
27
|
+
- lockfile: "yarn.lock"
|
|
28
|
+
manager: "yarn"
|
|
29
|
+
- lockfile: "bun.lockb"
|
|
30
|
+
manager: "bun"
|
|
31
|
+
- lockfile: "package-lock.json"
|
|
32
|
+
manager: "npm"
|
|
33
|
+
default: "npm"
|
|
34
|
+
install_command: "{manager} install"
|
|
35
|
+
|
|
36
|
+
route_detection:
|
|
37
|
+
server_indicators:
|
|
38
|
+
- pattern: 'require\(["\x27]express["\x27]\)|from ["\x27]express["\x27]'
|
|
39
|
+
description: "Express.js web framework"
|
|
40
|
+
frameworks: ["express"]
|
|
41
|
+
- pattern: 'require\(["\x27]fastify["\x27]\)|from ["\x27]fastify["\x27]'
|
|
42
|
+
description: "Fastify web framework"
|
|
43
|
+
frameworks: ["fastify"]
|
|
44
|
+
- pattern: 'from ["\x27]@nestjs/common["\x27]'
|
|
45
|
+
description: "NestJS framework"
|
|
46
|
+
frameworks: ["nestjs"]
|
|
47
|
+
- pattern: 'require\(["\x27]koa["\x27]\)|from ["\x27]koa["\x27]'
|
|
48
|
+
description: "Koa web framework"
|
|
49
|
+
frameworks: ["koa"]
|
|
50
|
+
- pattern: 'require\(["\x27]hono["\x27]\)|from ["\x27]hono["\x27]'
|
|
51
|
+
description: "Hono web framework"
|
|
52
|
+
frameworks: ["hono"]
|
|
53
|
+
- pattern: 'createServer|http\.Server'
|
|
54
|
+
description: "Node.js HTTP server"
|
|
55
|
+
frameworks: ["http"]
|
|
56
|
+
|
|
57
|
+
cli_indicators:
|
|
58
|
+
- pattern: 'require\(["\x27]commander["\x27]\)|from ["\x27]commander["\x27]'
|
|
59
|
+
description: "Commander.js CLI framework"
|
|
60
|
+
frameworks: ["commander"]
|
|
61
|
+
- pattern: 'require\(["\x27]yargs["\x27]\)|from ["\x27]yargs["\x27]'
|
|
62
|
+
description: "Yargs CLI framework"
|
|
63
|
+
frameworks: ["yargs"]
|
|
64
|
+
- pattern: 'require\(["\x27]@oclif/core["\x27]\)|from ["\x27]@oclif'
|
|
65
|
+
description: "Oclif CLI framework"
|
|
66
|
+
frameworks: ["oclif"]
|
|
67
|
+
- pattern: 'require\(["\x27]inquirer["\x27]\)|from ["\x27]inquirer["\x27]'
|
|
68
|
+
description: "Inquirer.js interactive CLI"
|
|
69
|
+
frameworks: ["inquirer"]
|
|
70
|
+
|
|
71
|
+
frontend_indicators:
|
|
72
|
+
- pattern: 'from ["\x27]react["\x27]|require\(["\x27]react["\x27]\)'
|
|
73
|
+
description: "React"
|
|
74
|
+
frameworks: ["react"]
|
|
75
|
+
- pattern: 'from ["\x27]vue["\x27]|createApp'
|
|
76
|
+
description: "Vue.js"
|
|
77
|
+
frameworks: ["vue"]
|
|
78
|
+
- pattern: 'from ["\x27]svelte["\x27]'
|
|
79
|
+
description: "Svelte"
|
|
80
|
+
frameworks: ["svelte"]
|
|
81
|
+
- pattern: 'from ["\x27]next["\x27]|from ["\x27]next/'
|
|
82
|
+
description: "Next.js"
|
|
83
|
+
frameworks: ["next"]
|
|
84
|
+
- pattern: 'defineNuxtConfig|from ["\x27]nuxt["\x27]'
|
|
85
|
+
description: "Nuxt"
|
|
86
|
+
frameworks: ["nuxt"]
|
|
87
|
+
|
|
88
|
+
patterns:
|
|
89
|
+
# Express / Koa style
|
|
90
|
+
- type: route
|
|
91
|
+
regex: '(app|router)\.(get|post|put|delete|patch|all)\s*\(\s*["\x27]([^"\x27]+)["\x27]'
|
|
92
|
+
groups: [_, method, path]
|
|
93
|
+
frameworks: ["express", "koa", "hono"]
|
|
94
|
+
# Fastify
|
|
95
|
+
- type: route
|
|
96
|
+
regex: '(fastify|server|app)\.(get|post|put|delete|patch)\s*\(\s*["\x27]([^"\x27]+)["\x27]'
|
|
97
|
+
groups: [_, method, path]
|
|
98
|
+
frameworks: ["fastify"]
|
|
99
|
+
# NestJS decorators
|
|
100
|
+
- type: route
|
|
101
|
+
regex: '@(Get|Post|Put|Delete|Patch)\s*\(\s*["\x27]([^"\x27]*)["\x27]?\s*\)'
|
|
102
|
+
groups: [method, path]
|
|
103
|
+
frameworks: ["nestjs"]
|
|
104
|
+
# Next.js app router (file-based)
|
|
105
|
+
- type: route
|
|
106
|
+
regex: 'export\s+(?:async\s+)?function\s+(GET|POST|PUT|DELETE|PATCH)'
|
|
107
|
+
groups: [method]
|
|
108
|
+
frameworks: ["next"]
|
|
109
|
+
# Commander CLI
|
|
110
|
+
- type: command
|
|
111
|
+
regex: '\.command\s*\(\s*["\x27]([^"\x27]+)["\x27]'
|
|
112
|
+
groups: [command_name]
|
|
113
|
+
frameworks: ["commander"]
|
|
114
|
+
# Yargs
|
|
115
|
+
- type: command
|
|
116
|
+
regex: '\.command\s*\(\s*["\x27]([^"\x27\s]+)'
|
|
117
|
+
groups: [command_name]
|
|
118
|
+
frameworks: ["yargs"]
|
|
119
|
+
|
|
120
|
+
import_analysis:
|
|
121
|
+
list_packages: null # TS doesn't have a native package lister
|
|
122
|
+
import_pattern: "from ['\"]([^'\"]+)['\"]|require\\(['\"]([^'\"]+)['\"]\\)"
|
|
123
|
+
source_extensions: [".ts", ".tsx", ".js", ".jsx", ".mjs", ".cjs"]
|
|
124
|
+
module_root_file: "package.json"
|
|
125
|
+
|
|
126
|
+
layer_conventions:
|
|
127
|
+
patterns:
|
|
128
|
+
- layer: 0
|
|
129
|
+
paths: ["src/types", "src/models", "types", "shared/types"]
|
|
130
|
+
description: "Type definitions, interfaces, schemas"
|
|
131
|
+
- layer: 1
|
|
132
|
+
paths: ["src/utils", "src/lib", "src/helpers", "utils", "lib"]
|
|
133
|
+
description: "Utility functions, depend only on types"
|
|
134
|
+
- layer: 2
|
|
135
|
+
paths: ["src/services", "src/core", "services", "core"]
|
|
136
|
+
description: "Business logic layer"
|
|
137
|
+
- layer: 3
|
|
138
|
+
paths: ["src/controllers", "src/handlers", "src/routes", "src/api"]
|
|
139
|
+
description: "HTTP/API handlers"
|
|
140
|
+
- layer: 4
|
|
141
|
+
paths: ["src/app", "src/pages", "src/index.ts", "src/main.ts"]
|
|
142
|
+
description: "Application entry points"
|
|
143
|
+
|
|
144
|
+
dependency_detection:
|
|
145
|
+
manifest_file: "package.json"
|
|
146
|
+
databases:
|
|
147
|
+
- pattern: '"(pg|postgres|@prisma/client|typeorm|knex|drizzle-orm|sequelize)"'
|
|
148
|
+
type: "postgres"
|
|
149
|
+
default_port: 5432
|
|
150
|
+
- pattern: '"(mysql2|mysql)"'
|
|
151
|
+
type: "mysql"
|
|
152
|
+
default_port: 3306
|
|
153
|
+
- pattern: '"(mongodb|mongoose|mongosh)"'
|
|
154
|
+
type: "mongodb"
|
|
155
|
+
default_port: 27017
|
|
156
|
+
- pattern: '"(redis|ioredis|@redis/client)"'
|
|
157
|
+
type: "redis"
|
|
158
|
+
default_port: 6379
|
|
159
|
+
- pattern: '"(better-sqlite3|sql.js)"'
|
|
160
|
+
type: "sqlite"
|
|
161
|
+
default_port: 0
|
|
162
|
+
services:
|
|
163
|
+
- pattern: '"(kafkajs|@kafka-js/confluent-schema-registry)"'
|
|
164
|
+
type: "kafka"
|
|
165
|
+
default_port: 9092
|
|
166
|
+
- pattern: '"(amqplib|amqp-connection-manager)"'
|
|
167
|
+
type: "rabbitmq"
|
|
168
|
+
default_port: 5672
|
|
169
|
+
- pattern: '"(@elastic/elasticsearch)"'
|
|
170
|
+
type: "elasticsearch"
|
|
171
|
+
default_port: 9200
|
|
172
|
+
env_var_patterns:
|
|
173
|
+
- pattern: 'process\.env\.([A-Z_][A-Z0-9_]*)'
|
|
174
|
+
- pattern: 'process\.env\[[\x27"]([A-Z_][A-Z0-9_]*)[\x27"]\]'
|
|
175
|
+
|
|
176
|
+
linter:
|
|
177
|
+
template_section: "typescript-linter"
|
|
178
|
+
script_extension: ".ts"
|
|
179
|
+
run_command: "npx ts-node scripts/lint-deps.ts"
|
|
180
|
+
|
|
181
|
+
naming:
|
|
182
|
+
file_pattern: "^[a-zA-Z][a-zA-Z0-9.-]*\\.(ts|tsx|js|jsx|mjs|cjs)$"
|
|
183
|
+
test_pattern: "^[a-zA-Z][a-zA-Z0-9.-]*\\.(test|spec)\\.(ts|tsx|js|jsx)$"
|
|
184
|
+
directory_style: "kebab-case"
|
|
185
|
+
|
|
186
|
+
ci:
|
|
187
|
+
github_actions:
|
|
188
|
+
image: "node:20"
|
|
189
|
+
setup_steps:
|
|
190
|
+
- "uses: actions/setup-node@v4\n with:\n node-version: '20'"
|
|
191
|
+
cache_paths: ["node_modules", ".next/cache"]
|
|
192
|
+
---
|
|
193
|
+
|
|
194
|
+
# TypeScript / JavaScript Adapter
|
|
195
|
+
|
|
196
|
+
## Package Manager Detection
|
|
197
|
+
|
|
198
|
+
TypeScript projects have multiple package managers. Detection priority:
|
|
199
|
+
|
|
200
|
+
| Lock File | Manager | Run Command |
|
|
201
|
+
|-----------|---------|-------------|
|
|
202
|
+
| `pnpm-lock.yaml` | pnpm | `pnpm run <script>` |
|
|
203
|
+
| `yarn.lock` | yarn | `yarn <script>` |
|
|
204
|
+
| `bun.lockb` | bun | `bun run <script>` |
|
|
205
|
+
| `package-lock.json` | npm | `npm run <script>` |
|
|
206
|
+
|
|
207
|
+
All `{pkg_manager}` placeholders in commands are resolved at detection time.
|
|
208
|
+
|
|
209
|
+
## Server Start Command Inference
|
|
210
|
+
|
|
211
|
+
1. Existing `harness/config/environment.json` startup command, if present
|
|
212
|
+
2. `package.json` → `scripts.start` exists → `{pkg_manager} start`
|
|
213
|
+
3. `package.json` → `scripts.dev` exists → `{pkg_manager} run dev`
|
|
214
|
+
4. `dist/index.js` exists → `node dist/index.js`
|
|
215
|
+
5. `src/index.ts` exists → `npx ts-node src/index.ts`
|
|
216
|
+
|
|
217
|
+
## Port Detection
|
|
218
|
+
|
|
219
|
+
1. Existing `harness/config/environment.json` readiness port, if present
|
|
220
|
+
2. `package.json` scripts containing `PORT=(\d+)` → use that port
|
|
221
|
+
3. `.env` containing `PORT=(\d+)` → use that port
|
|
222
|
+
4. Default: 3000 (frontend), 8080 (server)
|
|
223
|
+
|
|
224
|
+
## Framework-Specific Notes
|
|
225
|
+
|
|
226
|
+
### Next.js / Nuxt
|
|
227
|
+
- File-based routing: routes are derived from `app/` or `pages/` directory structure
|
|
228
|
+
- API routes: `app/api/**/route.ts` (Next.js App Router)
|
|
229
|
+
- Use `next build && next start` for production verification
|
|
230
|
+
|
|
231
|
+
### NestJS
|
|
232
|
+
- Decorator-based routing: `@Get()`, `@Post()`, `@Controller('prefix')`
|
|
233
|
+
- Module system: scan `*.module.ts` for service registration
|
|
234
|
+
- Default port: 3000
|
|
235
|
+
|
|
236
|
+
### Express / Fastify
|
|
237
|
+
- Explicit routing: `app.get('/path', handler)`
|
|
238
|
+
- Middleware chain matters for verification order
|
|
239
|
+
|
|
240
|
+
## Monorepo Support
|
|
241
|
+
|
|
242
|
+
If `workspaces` in `package.json` or `pnpm-workspace.yaml` exists:
|
|
243
|
+
- Run detection per-workspace
|
|
244
|
+
- Each workspace may have its own adapter overlay
|
|
245
|
+
- Build order respects workspace dependency graph
|