From 233c5f9a09ba82e94b042ac22462dcdfa8ffbae2 Mon Sep 17 00:00:00 2001 From: Justin Bedo Date: Fri, 6 Sep 2019 10:12:20 +1000 Subject: strelka: change outputs and tagging This resolves an issue where overriding the strelka derivations would lose the filetype tags. --- tools/strelka-call.nix | 10 +++------- tools/strelka-callSomatic.nix | 11 ++++------- 2 files changed, 7 insertions(+), 14 deletions(-) (limited to 'tools') diff --git a/tools/strelka-call.nix b/tools/strelka-call.nix index dc07291..a37c2aa 100644 --- a/tools/strelka-call.nix +++ b/tools/strelka-call.nix @@ -24,7 +24,6 @@ let out = stage { name = "strelka-call"; buildInputs = with pkgs; [ strelka ]; - outputs = [ "out" "variants" ]; buildCommand = '' ln -s ${ref} ref.fa ln -s ${bionix.samtools.faidx indexAttrs ref} ref.fa.fai @@ -50,12 +49,9 @@ out = stage { sed -i '/^##fileDate/d' $g sed -i '/^##startTime/d' $g done - mv variants.vcf $variants - ln -s $variants variants.vcf - mkdir $out - cp -r * $out + mv variants.vcf $out ''; passthru.multicore = true; + passthru.filetype = types.filetype.vcf {ref = ref;}; }; -ft = {filetype = types.filetype.vcf {ref = ref;};}; -in out // { variants = out.variants // ft; } +in out diff --git a/tools/strelka-callSomatic.nix b/tools/strelka-callSomatic.nix index cce6243..ec57b8c 100644 --- a/tools/strelka-callSomatic.nix +++ b/tools/strelka-callSomatic.nix @@ -26,7 +26,7 @@ let out = stage { name = "strelka-callSomatic"; buildInputs = with pkgs; [ strelka ]; - outputs = [ "out" "indels" "snvs" ]; + outputs = [ "indels" "snvs" ]; buildCommand = '' ln -s ${ref} ref.fa ln -s ${bionix.samtools.faidx indexAttrs ref} ref.fa.fai @@ -54,13 +54,10 @@ out = stage { sed -i '/^##startTime/d' $g done mv somatic.indels.vcf $indels - ln -s $indels somatic.indels.vcf mv somatic.snvs.vcf $snvs - ln -s $snvs somatic.snvs.vcf - mkdir $out - cp -r * $out ''; passthru.multicore = true; + passthru.filetype = types.filetype.vcf {ref = ref;}; }; -ft = {filetype = types.filetype.vcf {ref = ref;};}; -in out // { indels = out.indels // ft; snvs = out.snvs // ft;} + +in out -- cgit v1.2.3