[Rule Idea] Add a rule which remove automatically unneeded postgresql schema migrations
alexander-schranz opened this issue · 1 comments
alexander-schranz commented
There is an issue in doctrine migration which add some unexpected schema migrations in the down migration: doctrine/dbal#1110:
In my project it did contain the follwing:
$this->addSql('CREATE SCHEMA metric_helpers');
$this->addSql('CREATE SCHEMA user_management');
$this->addSql('CREATE SCHEMA public');
Think rector could be used to make sure this addSql never exists.
TomasVotruba commented
This sounds like a valid idea! Feel free to send PR with such a rule 👍
Closing as accepted to avoid keep issue tracker focus on unclear issues that needs our attention.