File tree 1 file changed +21
-3
lines changed
1 file changed +21
-3
lines changed Original file line number Diff line number Diff line change @@ -304,15 +304,33 @@ List<String> getExternalRuntimeDependencies(Project project) {
304
304
List<String > getExternalDependencies (Configuration configuration ) {
305
305
List<String > list = new ArrayList<> ();
306
306
configuration. dependencies. each { dep ->
307
-
307
+
308
308
// if the dependency is an external jar
309
309
if (dep instanceof ExternalDependency ) {
310
+ String name = dep. getName()
311
+ Set<String > classifiers = dep. artifacts. classifier
312
+ String group = dep. getGroup()
313
+ String version = dep. getVersion()
314
+ String searchString = name
315
+
316
+ if (version != null ) {
317
+ searchString = name+ " -" + version;
318
+ }
319
+
320
+ if (! classifiers. empty) {
321
+ String cls = classifiers. first()
322
+ if (cls != null ) {
323
+ searchString+ = " -$cls "
324
+ }
325
+ }
310
326
311
327
// loop back through all the dependency files, looking for one that contains the dependency name.
312
328
String depPath = configuration. find {
313
- it. name. contains(dep. name)
329
+ it. name. contains(searchString)
330
+ }
331
+ if (depPath == null ) {
332
+ println (" ****************DID NOT FIND DEPENDENCY: name = " + name+ " version = " + version)
314
333
}
315
-
316
334
// if we found the path, then add it to the list
317
335
if (depPath) {
318
336
list. add(depPath)
You can’t perform that action at this time.
0 commit comments