|
|
@ -85,14 +85,12 @@ public class AgentTasksEnhancer implements Action<Project> {
|
|
|
|
if (loaded != null) {
|
|
|
|
if (loaded != null) {
|
|
|
|
CodeSource source = loaded.getProtectionDomain().getCodeSource();
|
|
|
|
CodeSource source = loaded.getProtectionDomain().getCodeSource();
|
|
|
|
if (source != null) {
|
|
|
|
if (source != null) {
|
|
|
|
File agent;
|
|
|
|
|
|
|
|
try {
|
|
|
|
try {
|
|
|
|
agent = new File(source.getLocation().toURI());
|
|
|
|
return new File(source.getLocation().toURI());
|
|
|
|
}
|
|
|
|
}
|
|
|
|
catch (URISyntaxException ex) {
|
|
|
|
catch (URISyntaxException ex) {
|
|
|
|
agent = new File(source.getLocation().getPath());
|
|
|
|
return new File(source.getLocation().getPath());
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return agent;
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|