mirror of
https://github.com/rectorphp/rector.git
synced 2025-02-13 12:33:52 +01:00
commit
800ad48659
@ -27,10 +27,10 @@ foreach ($setProvider->provide() as $setName) {
|
||||
|
||||
|
||||
$process = new Process($command, __DIR__ . '/..');
|
||||
echo sprintf('Set "%s" is OK' . PHP_EOL, $setName);
|
||||
|
||||
try {
|
||||
$process->mustRun();
|
||||
echo sprintf('Set "%s" is OK' . PHP_EOL, $setName);
|
||||
} catch (ProcessFailedException $processFailedException) {
|
||||
if (! Strings::match($processFailedException->getMessage(), '#(Fatal error)|(\[ERROR\])#')) {
|
||||
continue;
|
||||
|
@ -1,5 +1,3 @@
|
||||
services:
|
||||
# first, run these rule → then look at step-1
|
||||
# add uuid id property
|
||||
Rector\Doctrine\Rector\Class_\AddUuidToEntityWhereMissingRector: ~
|
||||
Rector\Doctrine\Rector\Class_\AddUuidMirrorForRelationPropertyRector: ~
|
||||
Rector\Doctrine\Rector\Class_\AlwaysInitializeUuidInEntityRector: ~
|
||||
|
@ -1,9 +1,4 @@
|
||||
services:
|
||||
# properties
|
||||
Rector\Doctrine\Rector\Property\AddUuidAnnotationsToIdPropertyRector: ~
|
||||
Rector\Doctrine\Rector\Property\RemoveTemporaryUuidColumnPropertyRector: ~
|
||||
Rector\Doctrine\Rector\Property\RemoveTemporaryUuidRelationPropertyRector: ~
|
||||
|
||||
# methods
|
||||
Rector\Doctrine\Rector\ClassMethod\ChangeGetIdTypeToUuidRector: ~
|
||||
Rector\Doctrine\Rector\ClassMethod\ChangeSetIdTypeToUuidRector: ~
|
||||
# add relations uuid properties
|
||||
Rector\Doctrine\Rector\Class_\AddUuidMirrorForRelationPropertyRector: ~
|
||||
Rector\Doctrine\Rector\Class_\AlwaysInitializeUuidInEntityRector: ~
|
||||
|
@ -1,9 +1,9 @@
|
||||
services:
|
||||
Rector\Doctrine\Rector\MethodCall\ChangeSetIdToUuidValueRector: ~
|
||||
Rector\Doctrine\Rector\MethodCall\ChangeGetUuidMethodCallToGetIdRector: ~
|
||||
Rector\Doctrine\Rector\ClassMethod\ChangeReturnTypeOfClassMethodWithGetIdRector: ~
|
||||
Rector\Doctrine\Rector\Identical\ChangeIdenticalUuidToEqualsMethodCallRector: ~
|
||||
# properties
|
||||
Rector\Doctrine\Rector\Property\AddUuidAnnotationsToIdPropertyRector: ~
|
||||
Rector\Doctrine\Rector\Property\RemoveTemporaryUuidColumnPropertyRector: ~
|
||||
Rector\Doctrine\Rector\Property\RemoveTemporaryUuidRelationPropertyRector: ~
|
||||
|
||||
# add Uuid type declarations
|
||||
Rector\TypeDeclaration\Rector\ClassMethod\AddMethodCallBasedParamTypeRector: ~
|
||||
Rector\TypeDeclaration\Rector\ClassMethod\AddArrayReturnDocTypeRector: ~
|
||||
# methods
|
||||
Rector\Doctrine\Rector\ClassMethod\ChangeGetIdTypeToUuidRector: ~
|
||||
Rector\Doctrine\Rector\ClassMethod\ChangeSetIdTypeToUuidRector: ~
|
||||
|
9
config/set/doctrine/doctrine-id-to-uuid-step-4.yaml
Normal file
9
config/set/doctrine/doctrine-id-to-uuid-step-4.yaml
Normal file
@ -0,0 +1,9 @@
|
||||
services:
|
||||
Rector\Doctrine\Rector\MethodCall\ChangeSetIdToUuidValueRector: ~
|
||||
Rector\Doctrine\Rector\MethodCall\ChangeGetUuidMethodCallToGetIdRector: ~
|
||||
Rector\Doctrine\Rector\ClassMethod\ChangeReturnTypeOfClassMethodWithGetIdRector: ~
|
||||
Rector\Doctrine\Rector\Identical\ChangeIdenticalUuidToEqualsMethodCallRector: ~
|
||||
|
||||
# add Uuid type declarations
|
||||
Rector\TypeDeclaration\Rector\ClassMethod\AddMethodCallBasedParamTypeRector: ~
|
||||
Rector\TypeDeclaration\Rector\ClassMethod\AddArrayReturnDocTypeRector: ~
|
@ -1,12 +0,0 @@
|
||||
services:
|
||||
# first, run this rule
|
||||
Rector\Doctrine\Rector\Class_\AddUuidToEntityWhereMissingRector: ~
|
||||
|
||||
# second, diff and migrate wih Doctrine
|
||||
|
||||
# third, run this rule
|
||||
# Rector\Doctrine\Rector\Class_\AddUuidMirrorForRelationPropertyRector: ~
|
||||
|
||||
# fourth, diff and migrate wih Doctrine
|
||||
|
||||
# then run this to validate the change: bin/console doctrine:schema:update --dump-sql
|
Loading…
x
Reference in New Issue
Block a user