I think I figured something out. In the "base" project, in the parent pom,
I only defined the three modules in that project like this:
<modules>
<module>base-client</module>
<module>base-shared</module>
<module>base-server</module>
</modules>
but I changed it to add the client library like this:
<modules>
<module>base-client</module>
<module>../library-core/library-core-client</module>
<module>base-shared</module>
<module>base-server</module>
</modules>
and now the incremental compile works when I make changes to the library
client.
Is this the correct/best way to do this?
Thanks,
Will
On Friday, July 24, 2015 at 9:06:22 AM UTC-4, William Davis wrote:
>
> That is great news! I hope I can get your much appreciated assistance to
> help me figure out what I am doing wrong, because as of right now it isn't
> working for me. I am sure there is something I haven't configured properly
> so let me show you what I have.
>
> I am using the modular-webapp for the project with gwt-app. Similarly I
> wanted to have a library project that is divided by client, shared, and
> server projects.
>
> So my library set up is as follows:
>
>
> <https://lh3.googleusercontent.com/-a_EirKtIG2M/VbI0u-UtHhI/AAAAAAAAB1Y/8_7va8Frbqg/s1600/library%2Bstructure.PNG>
>
> Each one of those projects uses
>
> <packaging>gwt-lib</packaging>
>
> <build>
>
> <plugins>
>
> <plugin>
>
> <groupId>net.ltgt.gwt.maven</groupId>
>
> <artifactId>gwt-maven-plugin</artifactId>
>
> <version>1.0-rc-2</version>
>
> <extensions>true</extensions>
>
> <configuration>
>
> <moduleName>gwt.library.core.LibraryClient</moduleName>
>
> <moduleShortName>LibraryClient</moduleShortName>
>
> </configuration>
>
> </plugin>
>
> </plugins>
>
> </build>
>
>
> Of course the module name is different for the shared and server projects.
> So when I maven install the parent "library-core" project it will compile
> all 3 sub projects into their respective jars.
>
>
> Now I created a "base" project that depends on the library. This project
> was created with the modular-webapp archetype. In my base-client I depend
> on the library-core-client and my base-server depends on the
> library-core-server.
>
> For example in the base-client I have this:
>
> <dependency>
>
> <groupId>gwt.library</groupId>
>
> <artifactId>library-core-client</artifactId>
>
> <version>1.0.0-SNAPSHOT</version>
>
> <type>gwt-lib</type>
>
> </dependency>
>
>
>
>
> So when I run superdev like this:
>
> gwt:codeserver -pl *-client -am
>
> tomcat7:run -pl *-server -am -Denv=dev
>
>
> it all works, the dependencies play nice together, the only problem is if
> I change code in the library-core-client and refresh the browser, it does
> not detect the change.
>
>
> Am I missing something or is there a better way to structure the projects
> so they will work correctly?
>
>
> Thank you so much,
>
> Will
>
>
> On Friday, July 24, 2015 at 8:44:13 AM UTC-4, Thomas Broyer wrote:
>>
>>
>>
>> On Friday, July 24, 2015 at 2:33:22 PM UTC+2, William Davis wrote:
>>>
>>> Will the gwt-lib projects work with incremental compile or will I have
>>> to stop the dev mode, rebuild the library, and run again?
>>>
>>
>> One of the goals of net.ltgt.gwt.maven:gwt-maven-plugin was to properly
>> support multimodule projects, and "properly support" includes not having to
>> stop and restart devmode/codeserver when making changes in any module of
>> the reactor (and without hacks and/or profiles in your POMs).
>>
>
--
You received this message because you are subscribed to the Google Groups
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.