How to automatize maven projects reload

已回答

Hello.

I'm working on a Spring boot project that have several maven profiles:

We have a dedicated Git branch per environement, develop branch for dev env, release branch for staging env, etc.

My usual flow when I need to change env is as bellow:

1) Checkout the branch I need

2) Select the associated maven profile from the list (see first screenshot)

3) Reload all maven projects:

4) Then I am able to launch my server:

 

If I don't do step 3, maven projects reloading, the maven profile is not applied and the deploy fails. Is there a way to automatize this step in a "before launch" task? I tried maven goal "dependency:resolve" but it's not working.

 

Thank you!

0

Hello,

"Reload" should be executed automatically on selecting profile in 2023.3 version: https://youtrack.jetbrains.com/issue/IDEA-247509

0

请先登录再写评论。