File tree Expand file tree Collapse file tree 2 files changed +23
-2
lines changed
src/org/labkey/sequenceanalysis/run/util Expand file tree Collapse file tree 2 files changed +23
-2
lines changed Original file line number Diff line number Diff line change @@ -124,7 +124,7 @@ dependencies {
124124 BuildUtils . addExternalDependency(
125125 project,
126126 new ExternalDependency (
127- " com.github.broadinstitute:picard:3.1 .0" ,
127+ " com.github.broadinstitute:picard:3.4 .0" ,
128128 " Picard Tools Lib" ,
129129 " PicardTools" ,
130130 " https://github.com/broadinstitute/picard" ,
Original file line number Diff line number Diff line change @@ -368,7 +368,7 @@ private List<String> getBaseParams() throws FileNotFoundException
368368 throw new RuntimeException ("Not found: " + jbzip2 .getPath ());
369369 }
370370
371- File htsjdkJar = new File (libDir , "htsjdk-4.0.0.jar " );
371+ File htsjdkJar = findJar (libDir , "htsjdk-" );
372372 if (!htsjdkJar .exists ())
373373 {
374374 throw new RuntimeException ("Not found: " + htsjdkJar .getPath ());
@@ -403,6 +403,27 @@ private List<String> getBaseParams() throws FileNotFoundException
403403 return params ;
404404 }
405405
406+ private File findJar (final File libDir , final String prefix )
407+ {
408+ if (!libDir .exists ())
409+ {
410+ throw new RuntimeException ("Missing directory: " + libDir );
411+ }
412+
413+ List <String > jarNames = Arrays .stream (libDir .list ()).filter (fn -> fn .startsWith (prefix )).sorted ().toList ();
414+ if (jarNames .isEmpty ())
415+ {
416+ throw new RuntimeException ("Unable to find JAR with prefix: " + prefix );
417+ }
418+
419+ if (jarNames .size () > 1 )
420+ {
421+ _logger .info ("More than one JAR found with prefix: " + prefix );
422+ }
423+
424+ return new File (libDir , jarNames .get (jarNames .size () - 1 ));
425+ }
426+
406427 private int getThreads ()
407428 {
408429 return _threads ;
You can’t perform that action at this time.
0 commit comments