Skip to content

Commit f1dfabb

Browse files
Merge 25.7 to 25.8
2 parents d4963ec + fcb737c commit f1dfabb

File tree

2 files changed

+24
-2
lines changed

2 files changed

+24
-2
lines changed

SequenceAnalysis/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ dependencies {
135135
BuildUtils.addExternalDependency(
136136
project,
137137
new ExternalDependency(
138-
"com.github.broadinstitute:picard:3.1.0",
138+
"com.github.broadinstitute:picard:3.4.0",
139139
"Picard Tools Lib",
140140
"PicardTools",
141141
"https://github.com/broadinstitute/picard",

SequenceAnalysis/src/org/labkey/sequenceanalysis/run/util/FastqcRunner.java

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@
4646
import java.io.InputStreamReader;
4747
import java.io.StringWriter;
4848
import java.util.ArrayList;
49+
import java.util.Arrays;
4950
import java.util.HashSet;
5051
import java.util.LinkedList;
5152
import java.util.List;
@@ -366,7 +367,7 @@ private List<String> getBaseParams() throws FileNotFoundException
366367
throw new RuntimeException("Not found: " + jbzip2.getPath());
367368
}
368369

369-
File htsjdkJar = new File(libDir, "htsjdk-4.0.0.jar");
370+
File htsjdkJar = findJar(libDir, "htsjdk-");
370371
if (!htsjdkJar.exists())
371372
{
372373
throw new RuntimeException("Not found: " + htsjdkJar.getPath());
@@ -401,6 +402,27 @@ private List<String> getBaseParams() throws FileNotFoundException
401402
return params;
402403
}
403404

405+
private File findJar(final File libDir, final String prefix)
406+
{
407+
if (!libDir.exists())
408+
{
409+
throw new RuntimeException("Missing directory: " + libDir);
410+
}
411+
412+
List<String> jarNames = Arrays.stream(libDir.list()).filter(fn -> fn.startsWith(prefix)).sorted().toList();
413+
if (jarNames.isEmpty())
414+
{
415+
throw new RuntimeException("Unable to find JAR with prefix: " + prefix);
416+
}
417+
418+
if (jarNames.size() > 1)
419+
{
420+
_logger.info("More than one JAR found with prefix: " + prefix);
421+
}
422+
423+
return new File(libDir, jarNames.get(jarNames.size() - 1));
424+
}
425+
404426
private int getThreads()
405427
{
406428
return _threads;

0 commit comments

Comments
 (0)