From 9ce65debe403b1f8d0202d0bac7ec6d5b38237e6 Mon Sep 17 00:00:00 2001 From: rhpvorderman Date: Tue, 7 Mar 2017 10:45:17 +0100 Subject: [PATCH] Changed VCFstats to check whether outputDir is a valid directory. --- .../scala/nl/lumc/sasc/biopet/tools/vcfstats/VcfStats.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/biopet-tools/src/main/scala/nl/lumc/sasc/biopet/tools/vcfstats/VcfStats.scala b/biopet-tools/src/main/scala/nl/lumc/sasc/biopet/tools/vcfstats/VcfStats.scala index e1c2f3539..6f7789176 100644 --- a/biopet-tools/src/main/scala/nl/lumc/sasc/biopet/tools/vcfstats/VcfStats.scala +++ b/biopet-tools/src/main/scala/nl/lumc/sasc/biopet/tools/vcfstats/VcfStats.scala @@ -74,7 +74,7 @@ object VcfStats extends ToolCommand { opt[File]('o', "outputDir") required () unbounded () maxOccurs 1 valueName "" action { (x, c) => c.copy(outputDir = x) } validate { - x => if (x == null) failure("Output directory required") else success + x => if (x.exists) succes else failure ("Valid output directory required") } text "Path to directory for output (required)" opt[File]('i', "intervals") unbounded () valueName "" action { (x, c) => c.copy(intervals = Some(x)) -- GitLab