busser / tfautomv

Generate Terraform moved blocks automatically for painless refactoring
https://github.com/busser/tfautomv
Apache License 2.0
693 stars 24 forks source link

Guide users when all moves could not be guessed #38

Open busser opened 1 year ago

busser commented 1 year ago

In some cases tfautomv cannot guess all moves that need to be made. For improved user experience, we could make the following changes:

nelg commented 1 year ago

The first case I had, tfautomv could not guess.

I had a module, called by a for_each going over a list. I removed the loop calling the module and split it out into a number of calls to the same module without the loop. It didn't seem to be able to figure this out.

busser commented 1 year ago

As mentioned on Reddit by HourglassDev, we should print a message when rerunning may find more moves.

This is the case when tfautomv found at least one move but the plan still isn't empty.

Updated the list in the issue description accordingly.