File tree Expand file tree Collapse file tree 1 file changed +7
-0
lines changed
src/main/java/fvarrui/maven/plugin/javapackager Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -828,6 +828,7 @@ private String getRequiredModules(File libsFolder) throws MojoExecutionException
828828 modulesList = Arrays .asList (modules .split ("," ))
829829 .stream ()
830830 .map (module -> module .trim ())
831+ .filter (module -> !module .isEmpty ())
831832 .collect (Collectors .toList ());
832833
833834 } else if (customizedJre && JavaUtils .getJavaMajorVersion () >= 9 ) {
@@ -845,6 +846,7 @@ private String getRequiredModules(File libsFolder) throws MojoExecutionException
845846 modulesList = Arrays .asList (modules .split ("\n " ))
846847 .stream ()
847848 .map (module -> module .trim ())
849+ .filter (module -> !module .isEmpty ())
848850 .filter (module -> !module .startsWith ("JDK removed internal" ))
849851 .collect (Collectors .toList ());
850852
@@ -856,6 +858,11 @@ private String getRequiredModules(File libsFolder) throws MojoExecutionException
856858
857859 modulesList .addAll (additionalModules );
858860
861+ if (modulesList .isEmpty ()) {
862+ getLog ().warn ("It was not possible to determine the necessary modules. all modules will be included" );
863+ modulesList .add ("ALL-MODULE-PATH" );
864+ }
865+
859866 getLog ().info ("- Modules: " + modulesList );
860867
861868 return StringUtils .join (modulesList , "," );
You can’t perform that action at this time.
0 commit comments