Skip to content

Specify the version of PHP-CS-Fixer #467

@mlocati

Description

@mlocati

Describe the feature
It'd be very useful to specify the version of PHP-CS-Fixer to be used.
People may want to specify the major version (tools: php-cs-fixer:v2) or the full version ((tools: php-cs-fixer:v2.2.20).

So, we'd have 3 cases:

  • tools: php-cs-fixer -> setup-php should fetch https://github.com/FriendsOfPHP/PHP-CS-Fixer/releases/latest/download/php-cs-fixer.phar
  • tools: php-cs-fixer:v2 -> setup-php should fetch https://cs.symfony.com/download/php-cs-fixer-v2.phar
  • tools: php-cs-fixer:v2.3.4 -> setup-php should fetch https://github.com/FriendsOfPHP/PHP-CS-Fixer/releases/download/v2.3.4/php-cs-fixer.phar

Version

  • I have checked releases, and the feature is missing in the latest patch version of v2.

Underlying issue
PHP-CS-Fixer rules and rule sets change across PHP-CS-Fixer versions: we should have a way to be sure about the version we fetch.

Describe alternatives
We now have to fetch the PHAR file of PHP-CS-Fixer with a curl call.

Additional context

Are you willing to submit a PR?
No, sorry 😉

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions