Running resource filters when using jetty:run

前端 未结 3 768
盖世英雄少女心
盖世英雄少女心 2021-02-08 20:15

I\'m using resource filtering on jsps, based on profiles. I\'m also developing locally using mvn jetty:run, but the filtering phase does not run.

How can I

3条回答
  •  闹比i
    闹比i (楼主)
    2021-02-08 20:56

    You may want to use the jetty:run-exploded goal rather than jetty:run. From the documentation:

    This goal first assembles your webapp into an exploded war file and then deploys it to Jetty.

    This may ensure that the appropriate war lifecycle phases are executed before the server is started.

    Also are you sure the jci profile is being activated? if another profile is specified for the build, the property won't enable the profile, see this bug for details.

    From John Casey's response:

    The above example is working as designed. The element is meant to specify that this profile will be activated if no other profiles are active in the build. Therefore, specific activation of any profile will cause this one to be deactivated.

提交回复
热议问题