-
Notifications
You must be signed in to change notification settings - Fork 93
Closed
Milestone
Description
If we try use 'thin.repo' with gradle-plugin the task 'thinResolve' throws java.lang.UnsupportedOperationException:
org.gradle.api.tasks.TaskExecutionException: Execution failed for task ':thinResolve'
Caused by: java.lang.UnsupportedOperationException
at org.springframework.boot.experimental.gradle.ThinLauncherPlugin$6$1.execute(ThinLauncherPlugin.java:258)
at org.springframework.boot.experimental.gradle.ThinLauncherPlugin$6$1.execute(ThinLauncherPlugin.java:244)
...
I think the problem is in the method
ThinLauncherPlugin .createResolveTask (line 253-258)
because 'Arrays.asList(...)' creates an immutable list (and 'args.add(...)' throws an Exception):
List<String> args = Arrays.asList("-Dthin.root=.",
"-Dthin.dryrun", "-jar",
thinJar.getArchiveName());
String thinRepo = getThinRepo(project);
if (thinRepo != null) {
args.add(1, "-Dthin.repo=" + thinRepo);
}
maven-plugin has no this problem because ArrayList is used:
List<String> cmd = new ArrayList<>(Arrays.asList(...));
Metadata
Metadata
Assignees
Labels
No labels