Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[TASK] Add more Rector rules #1372

Merged
merged 2 commits into from
Nov 16, 2024
Merged

[TASK] Add more Rector rules #1372

merged 2 commits into from
Nov 16, 2024

Conversation

oliverklee
Copy link
Contributor

No description provided.

@oliverklee oliverklee added this to the 8.0.0 milestone Nov 10, 2024
@oliverklee oliverklee self-assigned this Nov 10, 2024
@oliverklee oliverklee marked this pull request as draft November 10, 2024 18:42
github-actions[bot]

This comment was marked as off-topic.

@coveralls
Copy link

coveralls commented Nov 10, 2024

Coverage Status

coverage: 97.062%. remained the same
when pulling 432deb0 on task/rector-config
into 47fd5db on main.

@oliverklee oliverklee force-pushed the task/rector-config branch 2 times, most recently from f189307 to 620091d Compare November 10, 2024 22:51
@oliverklee oliverklee marked this pull request as ready for review November 10, 2024 22:52
@oliverklee oliverklee requested a review from JakeQZ November 10, 2024 22:52
Copy link
Contributor

@JakeQZ JakeQZ left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've struggled to find decent documentation. What I've found has been very sparse. Where are you getting your info from?

config/rector.php Outdated Show resolved Hide resolved
config/rector.php Outdated Show resolved Hide resolved
->withSets([
// Rector sets

LevelSetList::UP_TO_PHP_73,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Where are these documented? I can't find it.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

https://github.com/rectorphp/rector/blob/main/src/Set/ValueObject/LevelSetList.php and https://github.com/rectorphp/rector/blob/main/config/set/level/up-to-php73.php etc. Basically, the LevelSetList::UP_TO_PHP_* set lists are about raising the PHP language level to the corresponding PHP version.

config/rector.php Outdated Show resolved Hide resolved
// PHPUnit sets

PHPUnitSetList::PHPUNIT_90,
// PHPUnitSetList::PHPUNIT_100,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ditto.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done.

config/rector.php Outdated Show resolved Hide resolved
config/rector.php Outdated Show resolved Hide resolved
@oliverklee
Copy link
Contributor Author

I've struggled to find decent documentation. What I've found has been very sparse. Where are you getting your info from?

Mostly from reading the source code after clicking on the method/constant/class in the configuration file.

Also, I copy from the configuration files from other projects, e.g. https://github.com/FriendsOfTYPO3/tea/blob/main/rector.php (that also uses some TYPO3-specific rulesets).

@JakeQZ JakeQZ merged commit 746dd0f into main Nov 16, 2024
28 checks passed
@JakeQZ JakeQZ deleted the task/rector-config branch November 16, 2024 15:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants