Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update recipes 2024-11-04 #118

Conversation

symfony-php-recipes-bot
Copy link
Member

Q A
License MIT

The Symfony Recipes changed with version .
This PR contains the new definition for recipes.

Copy link

github-actions bot commented Nov 4, 2024

Thanks for the PR 😍

How to test these changes in your application

  1. Define the SYMFONY_ENDPOINT environment variable:

    # On Unix-like (BSD, Linux and macOS)
    export SYMFONY_ENDPOINT=https://raw.githubusercontent.com/schranz-php-recipes/symfony-recipes-php/flex/pull-118/index.json
    # On Windows
    SET SYMFONY_ENDPOINT=https://raw.githubusercontent.com/schranz-php-recipes/symfony-recipes-php/flex/pull-118/index.json
  2. Install the package(s) related to this recipe:

    composer req 'symfony/flex:^1.16'
    composer req 'zenstruck/foundry:^2.0'
  3. Don't forget to unset the SYMFONY_ENDPOINT environment variable when done:

    # On Unix-like (BSD, Linux and macOS)
    unset SYMFONY_ENDPOINT
    # On Windows
    SET SYMFONY_ENDPOINT=

Diff between recipe versions

In order to help with the review stage, I'm in charge of computing the diff between the various versions of patched recipes.
I'm going keep this comment up to date with any updates of the attached patch.

zenstruck/foundry

1.9 vs 1.10
diff --git a/zenstruck/foundry/1.9/config/packages/dev/zenstruck_foundry.php b/zenstruck/foundry/1.9/config/packages/dev/zenstruck_foundry.php
deleted file mode 100644
index a17b790..0000000
--- a/zenstruck/foundry/1.9/config/packages/dev/zenstruck_foundry.php
+++ /dev/null
@@ -1,11 +0,0 @@
-<?php
-
-declare(strict_types=1);
-
-use Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigurator;
-
-return static function (ContainerConfigurator $containerConfigurator): void {
-    $containerConfigurator->extension('zenstruck_foundry', [
-        'auto_refresh_proxies' => true,
-    ]);
-};
diff --git a/zenstruck/foundry/1.9/config/packages/test/zenstruck_foundry.php b/zenstruck/foundry/1.9/config/packages/test/zenstruck_foundry.php
deleted file mode 100644
index 1ca5a4f..0000000
--- a/zenstruck/foundry/1.9/config/packages/test/zenstruck_foundry.php
+++ /dev/null
@@ -1,9 +0,0 @@
-<?php
-
-declare(strict_types=1);
-
-use Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigurator;
-
-return static function (ContainerConfigurator $containerConfigurator): void {
-    $containerConfigurator->import(__DIR__.'/../dev/zenstruck_foundry.php');
-};
diff --git a/zenstruck/foundry/1.10/config/packages/zenstruck_foundry.php b/zenstruck/foundry/1.10/config/packages/zenstruck_foundry.php
new file mode 100644
index 0000000..c0c2fcd
--- /dev/null
+++ b/zenstruck/foundry/1.10/config/packages/zenstruck_foundry.php
@@ -0,0 +1,18 @@
+<?php
+
+declare(strict_types=1);
+
+use Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigurator;
+
+return static function (ContainerConfigurator $containerConfigurator): void {
+    if ($containerConfigurator->env() === 'dev') {
+        $containerConfigurator->extension('zenstruck_foundry', [
+            'auto_refresh_proxies' => true,
+        ]);
+    }
+    if ($containerConfigurator->env() === 'test') {
+        $containerConfigurator->extension('zenstruck_foundry', [
+            'auto_refresh_proxies' => true,
+        ]);
+    }
+};
diff --git a/zenstruck/foundry/1.9/manifest.json b/zenstruck/foundry/1.10/manifest.json
index 9fe1ceb..050fabb 100644
--- a/zenstruck/foundry/1.9/manifest.json
+++ b/zenstruck/foundry/1.10/manifest.json
@@ -4,5 +4,9 @@
     },
     "bundles": {
         "Zenstruck\\Foundry\\ZenstruckFoundryBundle": ["dev", "test"]
-    }
+    },
+    "conflict": {
+        "symfony/framework-bundle": "<5.3"
+    },
+    "aliases": ["foundry"]
 }
1.10 vs 2.0
diff --git a/zenstruck/foundry/1.10/config/packages/zenstruck_foundry.php b/zenstruck/foundry/2.0/config/packages/zenstruck_foundry.php
index c0c2fcd..c5c6f64 100644
--- a/zenstruck/foundry/1.10/config/packages/zenstruck_foundry.php
+++ b/zenstruck/foundry/2.0/config/packages/zenstruck_foundry.php
@@ -6,13 +6,9 @@ use Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigura
 
 return static function (ContainerConfigurator $containerConfigurator): void {
     if ($containerConfigurator->env() === 'dev') {
-        $containerConfigurator->extension('zenstruck_foundry', [
-            'auto_refresh_proxies' => true,
-        ]);
+        $containerConfigurator->extension('zenstruck_foundry', null);
     }
     if ($containerConfigurator->env() === 'test') {
-        $containerConfigurator->extension('zenstruck_foundry', [
-            'auto_refresh_proxies' => true,
-        ]);
+        $containerConfigurator->extension('zenstruck_foundry', null);
     }
 };

@alexander-schranz alexander-schranz merged commit 5c9c177 into schranz-php-recipes:main Nov 4, 2024
1 of 2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants