From 6aeba6149b7bb68d61141a8dc45114ad84d2615f Mon Sep 17 00:00:00 2001
From: Ruben Vorderman <r.h.p.vorderman@lumc.nl>
Date: Mon, 2 Sep 2019 10:51:54 +0200
Subject: [PATCH] Higher mem requirement, more concise bash invocation

---
 gatk.wdl | 13 +++++--------
 1 file changed, 5 insertions(+), 8 deletions(-)

diff --git a/gatk.wdl b/gatk.wdl
index 7b1c62e..9504de2 100644
--- a/gatk.wdl
+++ b/gatk.wdl
@@ -267,7 +267,7 @@ task MuTect2 {
         String outputStats = outputVcf + ".stats"
 
         Int memory = 4
-        Float memoryMultiplier = 3
+        Float memoryMultiplier = 4
         String dockerImage = "quay.io/biocontainers/gatk4:4.1.2.0--1"
     }
 
@@ -531,8 +531,9 @@ task CombineVariants {
         mkdir -p $(dirname "~{outputPath}")
 
         # build "-V:<ID> <file.vcf>" arguments according to IDs and VCFs to merge
-        # echoing the commands into a file is a workaround to avoid syntax errors when using shell
-        echo '#!/bin/bash
+        # Make sure commands are run in bash
+        bash -c '#!/usr/bin/env bash
+        set -eux
         ids=(~{sep=" " identifiers})
         vars=(~{sep=" " variantVcfs})
         V_args=$(
@@ -548,11 +549,7 @@ task CombineVariants {
         --filteredrecordsmergetype ~{filteredRecordsMergeType} \
         --out ~{outputPath} \
         $V_args
-        ' > run_combine.sh
-
-        chmod 700 run_combine.sh
-
-        ./run_combine.sh
+        '
     >>>
 
     output {
-- 
GitLab