1712 Commits (5c98a2cf8e3df53172ed34130302a3d362f90631)

Author SHA1 Message Date
Jordi Boggiano 5c98a2cf8e
Add phpstan-symfony to get type info about console InputInterface, fix many errors (#10476)
Extract common init/require commands functionality into PackageDiscoveryTrait
Extract some helper methods into BaseCommand for better types
2 years ago
Jordi Boggiano 3446091027
Merge branch '2.2' into main 2 years ago
Jordi Boggiano d124c13a42
Add hints when the arg of show is not found, fixes #10493 2 years ago
Jordi Boggiano 8053d794a8
Fix reinstall command not firing pre-install-cmd/post-install-cmd events, fixes #10508 (#10514) 2 years ago
Maximilian Bösing 1704466b74
Add abandoned flag to show/outdated commands package lists (#10485)
To synchronize `abandoned` information with JSON APIs and the `composer.json` information of a package, we should return the following types: `bool|non-empty-string`.
This will either state if a package is abandoned and, if there is a replacement declared, what replacement package should be used instead.

Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>
2 years ago
Jordi Boggiano bab974575c
Merge branch '2.2' into main 2 years ago
John Stevenson 0228e5b47d
Clean up properly if self-update fails (#10475) 2 years ago
Jordi Boggiano f9d61c0665
Add links to repo to fund/licenses/search commands and add links to docs to config command 3 years ago
Jordi Boggiano 06bb3c9179
Add links to repo to show/outdated commands package lists, fixes #9367 3 years ago
Niels Vanpachtenbeke 1c928466a9
Remove code blocks for php <7.2 compatibility (#10417) 3 years ago
Jordi Boggiano 4e6d54b731
Fix all 5.3 $this-in-closure usages 3 years ago
Jordi Boggiano 5805a68645
Fix some todos dropping support for older Symfony releases 3 years ago
Jordi Boggiano 0b3adc84da
Fix a few phpstan errors and add a php8+ baseline for the rest 3 years ago
Jordi Boggiano bf72afec44
Fix Symfony6 compat 3 years ago
Jordi Boggiano 8f1b3d21db
Add --no-scripts to all commands and disable plugins/scripts when running self-update (#10371)
* Add --no-scripts as global parameter available to all commands, and handle it by default when creating a Composer instance from Command::getComposer

* Disable scripts/plugins for self-update command, fixes #10351
3 years ago
Jordi Boggiano 4e8f3e85e2
Improve error reporting for repo priorities, refs #10339 3 years ago
Jordi Boggiano cc32ebcabd
Search improvements (#10336)
* Search performance improvements, add SEARCH_VENDOR type, fixes #10326, fixes #10324, fixes #10325

* Add extra optimization path for autocompletion of ^foo/* whereas the vendor is fully known, refs #10320
3 years ago
Jordi Boggiano a3e91b5be6
Add allow-plugins config value (#10314)
Fixes #5659

- Automatically switch off plugins by default in July 2022
- reword hash into object in schema

Co-authored-by: Nils Adermann <naderman@naderman.de>
3 years ago
Jordi Boggiano a4a89f1508
Update archive format docs, refs #10087 3 years ago
Jordi Boggiano 24ce1eddbd
Add composer/pcre dependency and use it everywhere instead of preg_* 3 years ago
Tizian Schmidlin 4f789a5f6d
Add "use-parent-dir" config to configure prompt when no composer.json is present in current dir (#10307)
Fixes #10299

Co-authored-by: Jordi Boggiano <j.boggiano@seld.be>
3 years ago
Jordi Boggiano 1cfdaf43f1
Fix new file being leftover if require in new dir fails to resolve requirements 3 years ago
Jordi Boggiano d86049565d
Deactivate plugins before recreating a new composer instance and loading new plugins in require/remove commands, fixes #9962 3 years ago
Jordi Boggiano 91548d178b
Add support for setting platform packages to false to disable them (#10308)
Fixes #9664
3 years ago
Yehuda Katz ebf4cbdc69
Add COMPOSER_NO_DEV environment variable to set the --no-dev flag (#10262) 3 years ago
Rafael Dohms 78583ab678
Support ignore-platform-reqs in `composer outdated` (#10293)
This allows users to also find libraries that require major platform
changes to unlock updates.
It addresses #10291.
3 years ago
Jordi Boggiano f509c41280
Upgrade PHPStan to 1.0 (#10253)
Co-authored-by: Martin Herndl <martin@herndl.org>
3 years ago
Stephan 44c5b6cde6
Config: add source option for command to show where a config value is loaded from (#10129) 3 years ago
Martin Herndl 3013674c92
Refactor ignore platform reqs checks (#10079)
Introduces a `PlatformRequirementFilter` with methods that help to decide if a requirement is ignored or not as discussed in #10045 but without changing behaviour.
3 years ago
Jordi Boggiano bd4d624cc7
Read first from $_SERVER and $_ENV before using getenv (#10218) 3 years ago
Jordi Boggiano 85f3bb070d
Add abandoned flag in search command output 3 years ago
Jordi Boggiano 3bb78fd1ee
Make new phar filename random to avoid possible concurrency issues, refs #10252 3 years ago
Jordi Boggiano 6a7264fc2d
Trigger autoloading of a few classes before executing self-update command, fixes #10252 3 years ago
Jordi Boggiano 9f433aba76
Fix 9999999-dev showing on composer show when no branch alias is defined for the default branch, fixes #10260 3 years ago
Jordi Boggiano 44b69ba77f
Upgrade php-cs-fixer to 3.x and fix CS 3 years ago
Jordi Boggiano c65d09dff7
Fix @inheritDoc annotations 3 years ago
Samuel Felipe 3ccb54832b
PHPStan level 6 in src/Composer/Command (#10214) 3 years ago
Cédric Anne a7686e82f0
Filter candidates requiring an unknown platform package; fixes #10167 (#10184) 3 years ago
Anatoly Pashin b1a96a3141
PHPStan level 6 in src/Composer/Repository (#10197) 3 years ago
Jordi Boggiano 7d88de7d0b
Fix syntax 3 years ago
Jordi Boggiano 9599eb613b
Type annotations 3 years ago
Jordi Boggiano 4a7abd79c9
Fix 5.3 syntax 😒 3 years ago
Jordi Boggiano 759a3a9300
Fix require reverting changes even though dependency resolution succeeded if when something fails afterwards, closes #10118 3 years ago
Jordi Boggiano f776f52474
Hint composer require alternatives if dep resolution fails, fixes #10136 3 years ago
Jordi Boggiano f587237c55
Fix diagnose output when libz is not present for curl, refs #10153 3 years ago
Jordi Boggiano d1c8a4d1b4
Lots of typing improvements 3 years ago
Jordi Boggiano b3eebeb3b9
Merge pull request from GHSA-frqg-7g38-6gcf 3 years ago
Jordi Boggiano 532c6e7933
Fix show --all showing only the installed version if the package is installed, fixes #10095 3 years ago
Jordi Boggiano 0761474599
Add type info to many properties/methods 3 years ago
Jordi Boggiano d3c176ec69
PHPStan Level 5 (#10070)
* Bump PHPStan to level 5

* Update seld/phar-utils to latest

* Add phpstan-setup / phpstan scripts
3 years ago