简体   繁体   English

Intellij中的多模块Grails项目

[英]Multi-module Grails project in Intellij

Have a very basic scenario (at least in Maven world): 有一个非常基本的场景(至少在Maven世界中):

  1. We use latest grails 2.3.6 我们使用最新的grails 2.3.6
  2. We have Core project(plugin) 我们有核心项目(插件)
  3. We have multiple other projects( app1 , app2 , app3 ) depending on Core project 根据核心项目,我们还有多个其他项目( app1app2app3

Resolution block inside of BuildConfig has "pom true" and dependencies between modules are set up inside of pom.xml BuildConfig内部的解析块具有“ pom true”,并且模块之间的依赖关系在pom.xml内部设置

This set up works pretty well outside of intellij - you build and deploy Core project to your local maven repo then you build other projects. 这种设置在intellij之外非常有效-您将Core项目构建并部署到本地Maven存储库,然后再构建其他项目。

But in intelliJ I would expect to be able to modify both project( app1 and core ) at the same time without having to rebuild core project every time I touch it. 但是在智能方面,我希望能够同时修改两个项目( app1core ),而不必每次触摸它都重新构建核心项目。 I imported app1 to intellij then added core as a module. 我将app1导入intellij,然后将core作为模块添加。 Then everything compiled and built fine BUT whenever I try to click on a reference to a class in core from app1 it opens another dependency from target/work/plugins/app1 然后,每当我尝试单击app1中对核心类的引用时,所有内容都会编译并构建良好的BUT,这会打开target / work / plugins / app1中的另一个依赖项

I tried disabling that directory but it didn't work... Any suggestions? 我尝试禁用该目录,但是它不起作用...有任何建议吗?

为避免每次核心插件更改时都必须显式重建app1,app2,app3,请在这些应用中将核心插件定义为本地插件

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM