Commit Graph

11207 Commits

Author SHA1 Message Date
Tomas Votruba
a8a11cdead
[CodingStyle] Fix extra space on no extra import (#5777) 2021-03-05 01:16:22 +01:00
Matthias Pigulla
a2e36d5a04
Use the autoloader from where Rector was installed, not started (#5772)
* Use the autoloader from where Rector was installed, not started

* Remove autoloader already covered in AutoloadIncluder::includeDependencyOrRepositoryVendorAutoloadIfExists()

* Fix path to project autoloader

When Rector is installed as a project dependency through composer,
this script it will be in {vendor}/rector/rectory/bin/rector.php,
so ../../.. is where autoload.php lives.
2021-03-04 15:02:07 +01:00
Jan Mikeš
ab8a1e517d
[Docker] Setup QEMU for multiarch builds (#5774) 2021-03-04 14:40:51 +01:00
Jan Mikeš
7e131b91c9
[Docker] Support multiple CPU architectures - arm64 + amd64 (#5773) 2021-03-04 13:51:33 +01:00
Matthias Pigulla
a2bebbed5c
Generate Docker tags in more efficient way (#5732) 2021-03-04 11:37:42 +01:00
Tomas Votruba
aa36ff4a9b
[Transform] Add NativeTestCaseRector (#5765) 2021-03-03 23:10:25 +00:00
Tomas Votruba
a63b232eca
cleanup (#5763) 2021-03-03 21:51:04 +00:00
Tomas Votruba
382f146eaf
Merge CoreRectorInterface (#5762) 2021-03-03 22:28:27 +01:00
Tomas Votruba
bfa5416077
drop AbstactCommand, inline (#5761) 2021-03-03 19:34:32 +00:00
Jan Mikeš
124a13dde8
[Docker] Support multiple PHP versions for xdebug + blackfire images (#5760) 2021-03-03 18:48:43 +01:00
Tomas Votruba
c1dab30664
[MockistaToMockery] Drop as mockista is completely dead package (#5758) 2021-03-03 18:40:45 +01:00
Jan Mikeš
f3cdb06adf
Drop no longer needed secured rector version of Docker image (#5759) 2021-03-03 17:37:59 +00:00
Tomas Votruba
c559114715
remove stub loader where not needed (#5757)
Co-authored-by: kaizen-ci <info@kaizen-ci.org>
2021-03-03 17:15:12 +00:00
Tomas Votruba
0a7ce80f4f
[Renaming] Fix importing of just renamed function (#5755)
Co-authored-by: Michal Lulco <lulco@efabrica.sk>
2021-03-03 12:54:03 +00:00
Tomas Votruba
9f96242e8a
[TypeDeclaration] Remove AbstractTypeDeclarationRector (#5753) 2021-03-03 13:27:16 +01:00
othercorey
bb4b8dcdc6
Add missing CAKEPHP_42 setlist (#5752) 2021-03-03 18:57:21 +07:00
Tomas Votruba
516b4b94fa
[Defluent] Remove AbstractFluentChainMethodCallRector (#5751) 2021-03-03 12:57:04 +01:00
Tomas Votruba
98f4554ba2
[Symfony] Remove AbstractToConstructorInjectionRector (#5749) 2021-03-03 11:57:11 +01:00
Abdul Malik Ikhsan
5aa715bb2f
[Symfony4] Handle Ternary with null if in ConsoleExecuteReturnIntRector (#5747) 2021-03-03 10:35:32 +00:00
Tomas Votruba
8cd5d86c03
[Nette] Remove AbstractWithFunctionToNetteUtilsStringsRector (#5746) 2021-03-03 11:30:17 +01:00
Abdul Malik Ikhsan
8430a8d73a
[Symfony4] Skip ConsoleExecuteReturnIntRector on ternary returns number (#5735) 2021-03-03 11:24:17 +01:00
Oliver Nybroe
896a87c631
Change success message (#5745) 2021-03-03 11:22:17 +01:00
Tomas Votruba
92f2c5b3a6
[Nette] Remove AbstractWithFunctionToNetteUtilsStringsRector (#5742)
Co-authored-by: kaizen-ci <info@kaizen-ci.org>
2021-03-03 09:40:03 +00:00
Abdul Malik Ikhsan
abdc91606d
[Privatization] Skip PrivatizeLocalOnlyMethodRector on use Symfony Route Attribute (#5737)
Co-authored-by: Stephan Vierkant <stephan@vierkant.net>
Co-authored-by: kaizen-ci <info@kaizen-ci.org>
2021-03-03 10:33:46 +01:00
Abdul Malik Ikhsan
ef6ad7d063
[Naming] Skip UnderscoreToCamelCaseLocalVariableNameRector on used next/prev assign var as ArrayDimFetch (#5741)
Co-authored-by: Alexey Kopytko <alexey@kopytko.com>
Co-authored-by: kaizen-ci <info@kaizen-ci.org>
2021-03-03 10:32:46 +01:00
Tomas Votruba
b7b6725364
remove abstract (#5736) 2021-03-03 08:49:57 +00:00
Tomas Votruba
3673e2182c
[StaticReflection] Add OptimizedDirectorySourceLocator to speedup directory analysis (#5727)
Co-authored-by: kaizen-ci <info@kaizen-ci.org>
2021-03-02 23:42:53 +00:00
Jan Mikeš
cdd11f69c6
[Docker] Documented multiple supported PHP versions (#5734) 2021-03-02 22:16:38 +01:00
Jan Mikeš
013c7c7ca3
[CI][Docker] Fix missing image when tagging (#5731) 2021-03-02 15:27:07 +01:00
Jan Mikeš
f7b65a09b2
[CI][Docker] Merge Docker image tagging jobs (#5730) 2021-03-02 15:20:34 +01:00
Jan Mikeš
00833e1ca1
Allow failure of pushing additional tags (#5729) 2021-03-02 15:06:13 +01:00
Jan Mikeš
85298cfff7
Add additional tags on Docker images based on git ref (#5726) (#5728) 2021-03-02 14:59:33 +01:00
TomasVotruba
c6bf799da4 simplify complexity 2021-03-02 14:44:18 +01:00
Tomas Votruba
d5bf66f9cd
[CI] run rules dir by dir to identify static reflection weak sposts (#5720)
* [CI] run rules dir by dir to identify static reflection weak sposts

* [ci-review] Rector Rectify

* consistency

* remove unused property

* add data provider test fixture

* add InvertedIfFactory to lower complexity

* [DeadCode] Skip unused public method if data provider

* misc

* [DeadCode] Do not remove class method if required by parent ocntract

* make use of ContextAnalyzer to find the loop

* narrow dirs one level

* narrow packages

* narrow

* use directly

* narrow

* correct constant name to keep BC

* bump deps

* add version_compare to removed extra params, just to be sure

* do not return function node on unchanged name

* narrow

* add support for multiple variants

* widen

* remove double check [skip ci]

Co-authored-by: kaizen-ci <info@kaizen-ci.org>
2021-03-02 14:43:36 +01:00
Jan Mikeš
66f6b4a573
Fix name of Docker image (#5726) 2021-03-02 14:31:45 +01:00
Matthias Pigulla
ff93a759e6
Build "scoped" Docker images in GitHub Actions (#5667)
* Improve GHA build process to provide scoped Docker images for PHP 7.3-8.0

* Push cached build layers to Docker Hub instead of ghcr.io

* Build "-secured" Docker image

* Run Docker publish workflow for the "experimental-scoped" branch

* Use "plain" progress output from buildx

* Build only one image named "secured", based on PHP 8.0
2021-03-02 14:25:39 +01:00
Matthias Noback
0ffabe49ad
Point to the new parser nodes docs URL (#5722) 2021-03-02 12:28:11 +01:00
Tomas Votruba
11dab764e6
[PHPStanStaticTypeMapperChecker] Drop as very limited testing benefit, overly protective (#5721) 2021-03-02 11:22:49 +00:00
Abdul Malik Ikhsan
4758dad9b1
[Naming] Handle UnderscoreToCamelCaseLocalVariableNameRector in used in next and previous assign variable (#5718)
* Fixture for UnderscoreToCamelCaseLocalVariableNameRector

See #5715

* try

* fixture

* Closes #5716 Fixes #5715

* final touch

* [ci-review] Rector Rectify

Co-authored-by: Alexey Kopytko <alexey@kopytko.com>
Co-authored-by: kaizen-ci <info@kaizen-ci.org>
2021-03-01 17:45:54 +01:00
Tomas Votruba
05788745fd
[Downgrade] Remove excessive abstract class inheritance, use single service (#5717) 2021-03-01 12:10:50 +00:00
Tomas Votruba
47743269e8
Removing parent classes (#5714) 2021-03-01 02:28:35 +01:00
Tomas Votruba
da5f4a08c8
remove unmatched errors + require string in object types to avoid prefixing of generics objects (#5713) 2021-03-01 00:56:08 +00:00
addshore
b14ba760e9
[TypeDeclaration] Fixes for array dataProviders with multiple types (#5659)
More changes to PHPUnitDataProviderParamTypeInferer which I think
brings this to completeness in terms of what we want to expect.
2021-03-01 01:46:19 +01:00
Tomas Votruba
8c3443b036
[DX] Removing more parent abstract circular classes (#5709)
Co-authored-by: kaizen-ci <info@kaizen-ci.org>
2021-02-28 15:16:17 +00:00
Abdul Malik Ikhsan
a62bb98fe9
[EarlyReturn] Handle Return Parent next if on ChangeAndIfToEarlyReturnRector (#5711)
* Add failing test fixture for ChangeAndIfToEarlyReturnRector

# Failing Test for ChangeAndIfToEarlyReturnRector

Based on https://getrector.org/demo/aef6b329-49b5-4f27-b23e-9e879a0e2e0b

* Closes #5707

* phpstan

* move find boolean and conditions to NodeRepository

* final touch

Co-authored-by: Markus Staab <maggus.staab@googlemail.com>
2021-02-28 16:07:12 +01:00
Abdul Malik Ikhsan
df101bcbb0
[EarlyReturn] Handle Always return on ChangeAndIfToEarlyReturnRector (#5706) 2021-02-28 13:59:46 +01:00
Tomas Votruba
d737f82d3c
[DX] Add forbidden parent classes (#5705) 2021-02-28 13:53:28 +01:00
Markus Staab
74a54f3bc4
Fix url to nodes-overview (#5695)
* Fix url to nodes-overview

* Update create_own_rule.md

* Update README.md
2021-02-28 10:36:32 +01:00
Abdul Malik Ikhsan
599df0ab0e
[CodeQuality] Handle Named Argument in ThrowWithPreviousExceptionRector (#5699)
* fixture #5697

* [CodeQuality] Fixes #5697 handle Named Argument in ThrowWithPreviousExceptionRector

* clean up

* ensure named "previous"

* final touch
2021-02-28 10:35:09 +01:00
Abdul Malik Ikhsan
9576d65326
[Rector-CI] Update EndBug/add-and-commit to v7.0.0 (#5700) 2021-02-28 10:32:21 +01:00