yii2-gii: Error at update by Composer

What steps will reproduce the problem?

I copy repository by git and run composer update to load vendor stuff, but installation failed:

 [Exception]
  Cannot apply patch Fix PHP 7 compatibility (https://yiisoft.github.io/phpunit-patches/phpunit_php7.patch)!

patch no exists in Windows CMD, need you something like “git bash”

Additional info

Q A
Yii version no installed yet
PHP version 7.3
Database version no matter
Operating system windows 10

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Comments: 26 (25 by maintainers)

Most upvoted comments

What a mess, to be honest 😃 Maybe it’s better to send a pull request to original repository?

@samdark phpunit/* too not your repositories but they are patched (:

can’t patch the patcher using patcher

then plan B:

{
    "scripts": {
        "post-package-install": [
            "php -r \"{patch the patcher}\"
        ]
    }
}

@samdark “better” is not change external packages as it is now

@samdark hm… i think you don’t understand me

{
   "extra": {
       ...
        "composer-exit-on-patch-failure": false,
        "patches": {
            "cweagans/composer-patches": {
                "Fix Win compatibility": "...",
            },
            ...
        }
    }
}