detect-stack
Detect Stack
Analyze the current codebase and generate .agents/stack-context.md. Run this on first use in a project, or when the stack context is missing or stale.
What to Detect
Scan the project root for these signals:
Language — Count file extensions (.rs, .py, .ts, .go, .swift, .java, .rb, .cs, .ex, etc.). Primary = most files. Note secondary languages.
Framework — Read the package manifest:
Cargo.toml→ check[dependencies]for axum, actix, rocket, sqlx, diesel, tokiopackage.json→ check for react, next, svelte, express, fastify, prismago.mod→ check for gin, echo, fiber, chi, sqlcpyproject.toml/requirements.txt→ check for django, flask, fastapi, sqlalchemyGemfile→ check for rails, sinatraPackage.swift→ check for Vapor; scan for SwiftUI importsmix.exs→ check for phoenix, ecto
More from jordancoin/codingskills
kiss
When writing or reviewing code to reduce complexity and improve readability. Use when the user says "simplify this," "too complex," "hard to read," "clean up," "what does this do," or "can't follow this code." For over-engineering concerns, see yagni. For structural clarity, see separation-of-concerns.
19yagni
When writing or reviewing code to prevent over-engineering and speculative features. Use when the user says "is this over-engineered," "do we need this," "should I add," "future-proof," or "just in case." For simplicity concerns, see kiss. For abstraction design, see solid.
16solid
When designing module boundaries, interfaces, or class hierarchies for maintainable architecture. Use when the user says "how should I structure this," "too coupled," "hard to test," "dependency injection," "single responsibility," or "interface design." For simpler structural concerns, see separation-of-concerns.
11dry
When writing or reviewing code to eliminate duplicated knowledge and business logic. Use when the user says "this is duplicated," "we have this in two places," "single source of truth," "DRY this up," or "shotgun surgery." For premature abstraction concerns, see yagni.
10law-of-demeter
When reviewing code for excessive coupling and deep object chains. Use when the user says "too coupled," "train wreck," "chained calls," "feature envy," "mocking is painful," or "this reaches too deep." For broader structural coupling, see solid.
9boy-scout-rule
When touching existing code and wanting to leave it better. Use when the user says "clean this up while I'm here," "should I fix this," "tech debt," "while I'm in this file," or "incremental improvement." For full refactoring, see solid or separation-of-concerns.
9