Commit 4189ca94 authored by Holger Brandl's avatar Holger Brandl

require existence of fastq inputs

parent 8b2eaaaf
......@@ -50,8 +50,8 @@ if (evalBash("which STAR").exitCode != 0) throw IllegalArgumentException("STAR a
System.getenv("NGS_TOOLS").let {
require(it.isNotBlank() && File(it).isDirectory) { "NGS_TOOLS is not defined but needed to locate star_qc.R" }
}
require(evalBash("type dge_star_counts2matrix").exitCode==0) {"dge_star_counts2matrix is missing"}
require(evalBash("type dge_bam_correlate").exitCode==0){"dge_bam_correlate is missing"}
require(evalBash("type dge_star_counts2matrix").exitCode == 0) { "dge_star_counts2matrix is missing" }
require(evalBash("type dge_bam_correlate").exitCode == 0) { "dge_bam_correlate is missing" }
println("validating inputs...")
......@@ -65,12 +65,14 @@ if (!File("${star_index}/SA").isFile())
// dge_create_star_index ${igenome}'
// make sure all fastq files do exist
fastqFiles.filter { !it.isFile }.let {
require(it.isEmpty()) { "Some fastq files do not exist ${it.map { it.absoluteFile }.joinToString(", ")}" }
}
println("running STAR using igenome '${igenome}' for the following files")
val jl = JobList(".starjobs")
//rm .starjobs
//fastqFiles=$(ls $baseDir/treps_pooled/*fastq.gz)
for (fastqFile in fastqFiles) {
println("submitting STAR job for $fastqFile")
......@@ -118,7 +120,8 @@ joblist.`package$`.`MODULE$`.ImplJobListUtils(jl).createHtmlReport()
// cleanup
evalBash("""rm - rf * STARgenome * .Log.progress.out _STARtmp * .SJ.out.tab *Log.out""")
evalBash("rm - rf *STARgenome *.Log.progress.out _STARtmp *.SJ.out.tab *Log.out")
// Do reporting and perform bam correlation (but don't wait for the results)
evalBash("""
......
......@@ -10,6 +10,6 @@ source $NGS_TOOLS/dge_workflow/dge_utils.sh
#git clone https://github.com/holgerbrandl/kutils && cd kutils && gradle install && cd .. && rm -rf kutils
star_align.kts /local2/igenomes/Mus_Musculus/Ensembl/GRCm38 ~/test.fastq
star_align.kts /local2/igenomes/Mus_Musculus/Ensembl/GRCm38 ~/mouse_test.fastq.gz
mailme "star test done"
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment