Very often we need to quickly change something in source files of composer package (for example some Drupal module), and generate a patch with those changes.
This can be done via those steps, using drupal/search_api_solr
composer package as example :