/ Annuaire / Playground / symfony-hexagonal-skill
● Communauté aligundogdu ⚡ Instantané

symfony-hexagonal-skill

par aligundogdu · aligundogdu/symfony-hexagonal-skill

Enforces hexagonal architecture in Symfony projects — 10 auto-triggered skills plus 2 review agents that stop you from leaking infrastructure into domain.

A Claude Code plugin for Symfony developers who actually want to keep ports & adapters clean. Auto-triggers on Symfony code patterns to guide domain/application/infrastructure separation. Includes review agents that catch leaks (Doctrine entities imported into domain, controllers calling repositories directly).

Pourquoi l'utiliser

Fonctionnalités clés

Démo en direct

Aperçu en pratique

symfony-hexagonal-skill.replay ▶ prêt
0/0

Installation

Dépôt de l’auteur · Documentation officielle des Skills Claude

Cas d'usage

Usages concrets : symfony-hexagonal-skill

Scaffold a new bounded context with hexagonal layers

👤 Symfony devs building non-trivial domain logic ⏱ ~60 min advanced

Quand l'utiliser : You're starting a new feature and want the layering right from day one.

Déroulement
  1. Name the context
    Use symfony-hexagonal-skill. Scaffold a 'Billing' bounded context with Invoice aggregate, issue/void commands, and a query for open invoices.✓ Copié
    → src/Billing/Domain, Application, Infrastructure folders with proper separation
  2. Wire the infrastructure
    Add a Doctrine adapter for InvoiceRepository behind the domain port.✓ Copié
    → Interface in Domain, implementation in Infrastructure, services.yaml binding
  3. Expose via controller
    Add an HTTP adapter with a POST /invoices endpoint that dispatches the IssueInvoice command.✓ Copié
    → Controller calls bus, not repository directly

Résultat : A clean bounded context that won't turn into spaghetti in 6 months.

Pièges
  • Domain depending on Doctrine annotations — Use XML / attribute mapping in Infrastructure, not on domain entities
Combiner avec : filesystem

Review a PR for hexagonal layering violations

👤 Tech leads on Symfony teams ⏱ ~20 min intermediate

Quand l'utiliser : Reviewing a PR and you want an automated first-pass on layering.

Déroulement
  1. Run the review agent
    Use symfony-hexagonal-skill review agent on this diff. Flag any Doctrine / Symfony FW imports in Domain/, any controller->repository direct calls, any ORM leakage into responses.✓ Copié
    → Concrete findings with file+line
  2. Suggest fixes
    For each finding, propose the minimal refactor.✓ Copié
    → Diffs introducing a port or DTO

Résultat : A PR that doesn't silently degrade the architecture.

Combiner avec : github

Progressively refactor an existing Symfony app toward hexagonal

👤 Teams with a legacy Symfony project ⏱ ~120 min advanced

Quand l'utiliser : Big-bang rewrite is off the table; you want incremental cleanup.

Déroulement
  1. Identify a seam
    Use symfony-hexagonal-skill. Look at src/Module/Orders — what's the smallest slice I can lift into a clean domain?✓ Copié
    → Specific class identified with extraction plan
  2. Extract incrementally
    Walk me through the extraction in 3 PR-sized steps.✓ Copié
    → Staged plan with tests preserved at each step

Résultat : A legacy codebase getting better, one PR at a time.

Pièges
  • Extracting too much in one step — PR-sized slices only; the plugin's review agent helps gate each step
Combiner avec : git

Combinaisons

Associez-le à d'autres MCPs pour un effet X10

symfony-hexagonal-skill + github

Gate PRs on layering review before merge

Run the hex review on the open PR in this repo and post findings as comments.✓ Copié
symfony-hexagonal-skill + filesystem

Apply scaffolds into the actual repo

Apply the context scaffold to my project under src/.✓ Copié

Outils

Ce que ce MCP expose

OutilEntréesQuand appelerCoût
context_scaffold context name, aggregates New bounded context 0
port_adapter_pair port interface name, adapter type Adding infrastructure 0
layering_review diff or directory Pre-merge 0
refactor_plan legacy module Starting a cleanup 0

Coût et limites

Coût d'exécution

Quota d'API
None
Tokens par appel
Moderate — reviews scan files
Monétaire
Free
Astuce
Scope reviews to the diff, not whole repos, to save tokens.

Sécurité

Permissions, secrets, portée

Stockage des identifiants : None
Sortie de données : None from skill

Dépannage

Erreurs courantes et correctifs

Review agent misses violations

Ensure the full diff is in context; very large diffs may need chunking

Scaffold produces old Symfony 5 style

Mention your Symfony version explicitly — 6 vs 7 conventions differ

Alternatives

symfony-hexagonal-skill vs autres

AlternativeQuand l'utiliserCompromis
Deptrac static analysisYou want rule-based static enforcement of layeringNo refactor help; purely gates violations
craftcms-claude-skillYou're on Craft CMS, not SymfonyDifferent framework

Plus

Ressources

📖 Lire le README officiel sur GitHub

🐙 Voir les issues ouvertes

🔍 Parcourir les 400+ serveurs MCP et Skills