Hi there,

Currently, when I use maven to build the project I have this problem.

I have 2 projects: desk_post and desk_post_test (required desk_post)

When I run for desk_post

-> mvn clean install

-> successful

-> created: desk_post-1.00.08.00-SNAPSHOT.iar

-> the resources folder already included in iar file alt text

Then I run for desk_post_test

-> mvn clean test -X

-> not successful

I open the folder desk_post_test\target\ivyBuildApp\iarJars\

I can not find the resources anymore (see the picture) alt text

Unfortunately, I have to use that resource

I used: Ivy 6.3.0

Do you have any idea?

This is one log in command line:

[INFO] Compiling ivy Project...
[DEBUG] Create jar 'C:\work\finform_workspace\6.3\postfinance_desk\desk_post_test\target\ivyBuildApp\iarJars\desk_post-1.00.08.00-SNAPSHOT.jar' with java binaries from ivy archive 'C:\Users\vdkhanh\.m2\repository\ch\axonivy\finform\desk_post\1.00.08.00-SNAPSHOT\desk_post-1.00.08.00-SNAPSHOT.iar'

asked 07.06.2017 at 08:22

khanh11166's gravatar image

khanh11166
51349
accept rate: 0%


I just checked in the newest code base. And I agree that resources will never be accessible in dependent projects.

The reason is exactly the log line you mentioned. We build a simple jar with minimal contents (classes + embedded jars). Unfortunately we do not consider static resources.

As short fix you could pack all resources into a JAR file, copy this JAR into the ivyProject and add it to the classpath. Then the resources should be accessible by the maven build.

link

answered 07.06.2017 at 08:56

Reguel%20Wermelinger's gravatar image

Reguel Werme... ♦♦
7.1k11342
accept rate: 70%

Hi Reguel,

This short fix is OK for me. At least I have one way to fix this.

Thanks,

DK

(13.06.2017 at 02:42) khanh11166 khanh11166's gravatar image
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "Title")
  • image?![alt text](/path/img.jpg "Title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×11
×7
×3

Asked: 07.06.2017 at 08:22

Seen: 361 times

Last updated: 14.06.2017 at 02:59