How to require (include) forked repository in your project? Well if you try to just include it using composer require you will see next error message
quote
So here is what you need to do:
1. In composer.json add to require original repo with forked branch name
2. Add to composer.json repository with forked url
Confused? Here is an example:
So, the original repository is aws/aws-sdk-php-laravel and forked repo out of the original is Kussie/aws-sdk-php-laravel which BTW contains the needed changes and they are stored in branch called "laravel-8-support"
So to include the forked repo, open the composer.json and add this line to "require" section:
"require": {
...,
"aws/aws-sdk-php-laravel": "dev-laravel-8-support"
},
and then again in composer.json at the end add this:
"repositories": [
{
"type": "vcs",
"url": "https://github.com/Kussie/aws-sdk-php-laravel"
}
and now you can run the github command:
composer update
aaand...Your package will be installed 🤘