I'm working in a multi-module maven project in Intellij. There was a snapshot update in another module which required an update in a few POMs. Normally I will click the "Re-import all maven projects" from the maven plugins tool then do a full build.
However, this time the .iml files associated with the changed POMs weren't being updated. It wasn't until I did "Build->Rebuild Project" that the .iml files were updated. Does anyone know how to update .iml files as part of a build configuration?
Note: Before rebuilding the project, I know mvn at least picked up on the change because my local .m2 repo had the latest snapshot.
EDIT #1: So, this is also true if I add a maven runtime dependency in a module. It won't pick up the change unless I do rebuild project.
I've experienced similar issues with newer versions of IntelliJ (2018.2.7) where my .iml is out of date. It happens inconsistently, so I'm not sure what the root cause is, but the following work around allows me to avoid doing a full rebuild:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With