From d325a6d6ca541f1f5df453577ddf9dbba190b494 Mon Sep 17 00:00:00 2001 From: Nicolas Joubert Date: Mon, 12 Oct 2026 14:16:51 +0200 Subject: [PATCH] #90 - Document the Symfony Flex recipe MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit # Veuillez saisir le message de validation pour vos modifications. Les lignes # commençant par '#' seront conservées ; vous pouvez les supprimer vous-même # si vous le souhaitez. Un message vide abandonne la validation. # # rebasage interactif en cours ; sur 7b6a018 # Dernière commande effectuée (1 commande effectuée) : # pick 7d564dc #90 - Document the Symfony Flex recipe # Aucune commande restante. # Vous êtes en train de rebaser la branche '90' sur '7b6a018'. # # Modifications qui seront validées : # modifié : CHANGELOG.md # modifié : docs/01-quick_start.md # --- CHANGELOG.md | 3 +++ docs/01-quick_start.md | 20 +++++++++++++++++++- 2 files changed, 22 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8ea558a4..14a633a5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,9 @@ Latest ------ +## Changes +* [#90](https://github.com/cleverage/process-bundle/issues/90) Installation documentation: describe the Symfony Flex recipe ([symfony/recipes-contrib#2081](https://github.com/symfony/recipes-contrib/pull/2081)), which registers the bundle and creates `config/packages/clever_age_process.yaml` importing the `config/packages/process/` directory, and the manual setup without Flex. + v5.4 ----- diff --git a/docs/01-quick_start.md b/docs/01-quick_start.md index 1b62da0c..67bf7be8 100644 --- a/docs/01-quick_start.md +++ b/docs/01-quick_start.md @@ -30,12 +30,30 @@ Open a command console, enter your project directory and install it using compos composer require cleverage/process-bundle ``` -Remember to add the following line to `config/bundles.php` (not required if Symfony Flex is used): +With [Symfony Flex](https://symfony.com/doc/current/setup/flex.html), the +[recipe](https://github.com/symfony/recipes-contrib/tree/main/cleverage/process-bundle) registers the bundle and creates: +- `config/packages/clever_age_process.yaml`: the [global configuration](#global-configuration), which imports the + `config/packages/process/` directory, +- `config/packages/process/`: the directory of your processes, one file per process (see + [process definition](reference/01-process_definition.md)). + +Without Flex, add the following line to `config/bundles.php`: ```php CleverAge\ProcessBundle\CleverAgeProcessBundle::class => ['all' => true], ``` +Then create the `config/packages/process/` directory and the configuration that imports it: + +```yaml +# config/packages/clever_age_process.yaml +imports: + - { resource: process/ } + +clever_age_process: + default_error_strategy: stop +``` + Some tasks and transformers use the Symfony serializer (`NormalizerTask`, `DenormalizerTask`, `SerializerTask`, `DeserializerTask`, the `normalize` and `denormalize` transformers) or validator (`ValidatorTask`) services. If they are not enabled, the container still compiles, and a process using one of these tasks or transformers fails with an explicit