Dependency Direction¶
Dependency direction in bijux-cli should flow toward stable contracts and
feature services, not from low-level modules back into top-level command
interfaces.
Visual Summary¶
flowchart TD
caller["bin and api"] --> bootstrap["bootstrap"]
bootstrap --> interface["interface"]
interface --> routing["routing"]
interface --> features["features"]
features --> contracts["contracts"]
features --> infrastructure["infrastructure"]
interface --> shared["shared"]
Expected Direction Rules¶
binandbootstrapcall interface and API facadesinterfaceorchestrates but should not reimplement feature logicroutingnormalizes and resolves routes without owning business statefeaturesimplement domain behavior and consume contracts/infrastructurecontractsstay dependency-light and reusable by all layers
Code Anchors¶
crates/bijux-cli/src/lib.rscrates/bijux-cli/src/interface/cli/dispatch.rscrates/bijux-cli/src/routing/mod.rscrates/bijux-cli/src/features/mod.rscrates/bijux-cli/src/contracts/mod.rs
Anti-Patterns to Block¶
- handler modules importing deep implementation from unrelated features
- contract modules importing interface-specific behavior
- circular dependencies between interface and feature subtrees
- direct process side effects in parser-only modules
Evidence Anchors¶
- architecture boundary tests under
crates/bijux-cli/tests/architecture/boundaries/ - routing law tests under
crates/bijux-cli/tests/routing/laws/