Include Java project as library

后端 未结 9 1895
眼角桃花
眼角桃花 2021-02-10 13:48

I have three projects in my eclipse workspace:

EventKitchenCore
EventKitchenDesktop
EventKitchenAndroid

EventKitchenCore contains

9条回答
  •  说谎
    说谎 (楼主)
    2021-02-10 14:18

    You can configure your projects as a Maven Artifact that depends of EventKitchenCore, so, Maven will handle this for you:

    EventKitchenCore pom.xml:

    
       4.0.0
       com.adamgaskins
       event-kitchen-core
       jar
       0.0.1-SNAPSHOT
       EventKitchenCore
    
    

    EventKitchenDesktop pom.xml:

    
       4.0.0
       com.adamgaskins
       event-kitchen-desktop
       jar
       0.0.1-SNAPSHOT
       EventKitchenDesktop
       
         
           com.adamgaskins
           event-kitchen-core
           0.0.1-SNAPSHOT
         
       
    
    

    EventKitchenAndroid pom.xml:

    
       4.0.0
       com.adamgaskins
       event-kitchen-android
       apk 
       0.0.1-SNAPSHOT
       EventKitchenAndroid
       
         
           com.adamgaskins
           event-kitchen-core
           0.0.1-SNAPSHOT
         
       
    
    

    Don't forget of SNAPSHOT suffix, otherwise, Maven will not update your changes.

提交回复
热议问题