]> git.mxchange.org Git - friendica.git/commitdiff
Add Dice.php patch
authorPhilipp <admin@philipp.info>
Mon, 16 Jan 2023 20:12:47 +0000 (21:12 +0100)
committerPhilipp <admin@philipp.info>
Mon, 16 Jan 2023 20:55:23 +0000 (21:55 +0100)
composer.json
composer.lock
mods/patches/level-2-dice-dice-php.patch [new file with mode: 0644]

index c6746c1231c4f63827d664fe899248f53c0d6521..aab60ee5c608d6e0cc79662863c752b816bd5543 100644 (file)
@@ -28,6 +28,7 @@
                "ext-xml": "*",
                "asika/simple-console": "^1.0",
                "bacon/bacon-qr-code": "^2.0.0",
+               "cweagans/composer-patches": "^1.7",
                "divineomega/password_exposed": "^2.8",
                "ezyang/htmlpurifier": "^4.7",
                "friendica/json-ld": "^1.0",
                "mockery/mockery": "^1.3",
                "mikey179/vfsstream": "^1.6",
                "phpunit/phpunit": "^9",
-               "dms/phpunit-arraysubset-asserts": "^0.3.1"
+               "dms/phpunit-arraysubset-asserts": "^0.3.1",
+               "symplify/vendor-patches": "11.2.0.72"
        },
        "scripts": {
                "test": "phpunit",
                "cs:install": "@composer install --working-dir=bin/dev/php-cs-fixer",
                "cs:check": ["@cs:install", "bin/dev/php-cs-fixer/vendor/bin/php-cs-fixer fix --dry-run --diff"],
                "cs:fix": ["@cs:install", "bin/dev/php-cs-fixer/vendor/bin/php-cs-fixer fix"]
+       },
+       "extra": {
+               "patches": {
+                       "level-2/dice": [
+                         "mods/patches/level-2-dice-dice-php.patch"
+                       ]
+               }
        }
 }
index 63f8a0d5b090d2ac532e70b9dc4817aebdda9ba8..aa3f7eed3fd0a1facb91dc42992767ea541da040 100644 (file)
@@ -4,7 +4,7 @@
         "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
         "This file is @generated automatically"
     ],
-    "content-hash": "5af9ac9003f4653f3aa1860dd5a4d821",
+    "content-hash": "0bbc4011b7628c0d563f80f361e98cdd",
     "packages": [
         {
             "name": "asika/simple-console",
             ],
             "time": "2022-07-20T07:14:26+00:00"
         },
+        {
+            "name": "cweagans/composer-patches",
+            "version": "1.7.3",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/cweagans/composer-patches.git",
+                "reference": "e190d4466fe2b103a55467dfa83fc2fecfcaf2db"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/cweagans/composer-patches/zipball/e190d4466fe2b103a55467dfa83fc2fecfcaf2db",
+                "reference": "e190d4466fe2b103a55467dfa83fc2fecfcaf2db",
+                "shasum": ""
+            },
+            "require": {
+                "composer-plugin-api": "^1.0 || ^2.0",
+                "php": ">=5.3.0"
+            },
+            "require-dev": {
+                "composer/composer": "~1.0 || ~2.0",
+                "phpunit/phpunit": "~4.6"
+            },
+            "type": "composer-plugin",
+            "extra": {
+                "class": "cweagans\\Composer\\Patches"
+            },
+            "autoload": {
+                "psr-4": {
+                    "cweagans\\Composer\\": "src"
+                }
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "BSD-3-Clause"
+            ],
+            "authors": [
+                {
+                    "name": "Cameron Eagans",
+                    "email": "me@cweagans.net"
+                }
+            ],
+            "description": "Provides a way to patch Composer packages.",
+            "time": "2022-12-20T22:53:13+00:00"
+        },
         {
             "name": "dasprid/enum",
             "version": "1.0.3",
                 "x509",
                 "x690"
             ],
+            "abandoned": true,
             "time": "2021-12-11T12:41:06+00:00"
         },
         {
                 "phpunit/phpunit": "^6.5"
             },
             "type": "library",
+            "extra": {
+                "patches_applied": [
+                    "mods/patches/level-2-dice-dice-php.patch"
+                ]
+            },
             "autoload": {
                 "psr-4": {
                     "Dice\\": "./"
             ],
             "time": "2020-09-28T06:39:44+00:00"
         },
+        {
+            "name": "symplify/vendor-patches",
+            "version": "11.2.0.72",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/symplify/vendor-patches.git",
+                "reference": "83204e1a7a33ca958f9d1cc9c3b1b25f75270775"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/symplify/vendor-patches/zipball/83204e1a7a33ca958f9d1cc9c3b1b25f75270775",
+                "reference": "83204e1a7a33ca958f9d1cc9c3b1b25f75270775",
+                "shasum": ""
+            },
+            "require": {
+                "cweagans/composer-patches": "^1.7",
+                "php": ">=7.2"
+            },
+            "bin": [
+                "bin/vendor-patches"
+            ],
+            "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-main": "10.3-dev"
+                }
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "MIT"
+            ],
+            "description": "Generate vendor patches for packages with single command",
+            "funding": [
+                {
+                    "url": "https://www.paypal.me/rectorphp",
+                    "type": "custom"
+                },
+                {
+                    "url": "https://github.com/tomasvotruba",
+                    "type": "github"
+                }
+            ],
+            "time": "2023-01-11T09:41:31+00:00"
+        },
         {
             "name": "theseer/tokenizer",
             "version": "1.2.1",
diff --git a/mods/patches/level-2-dice-dice-php.patch b/mods/patches/level-2-dice-dice-php.patch
new file mode 100644 (file)
index 0000000..5319804
--- /dev/null
@@ -0,0 +1,10 @@
+--- /dev/null
++++ ../Dice.php
+@@ -257,6 +257,7 @@
+                                       for ($i = 0; $i < count($args); $i++) {
+                                               if (call_user_func('is_' . $param->getType()->getName(), $args[$i])) {
+                                                       $parameters[] = array_splice($args, $i, 1)[0];
++                                                      break;
+                                               }
+                                       }
+                               }