aboutsummaryrefslogtreecommitdiff
path: root/tools/strelka-call.nix
diff options
context:
space:
mode:
authorJustin Bedo <cu@cua0.org>2019-01-16 11:14:00 +1100
committerJustin Bedo <cu@cua0.org>2019-01-16 15:29:14 +1100
commitd9223958d2d83a936719694db63c4777a8dde274 (patch)
tree5cd44c1f1b61f607cf2aa8948f0ed7f0d978e2b1 /tools/strelka-call.nix
parent2bf74101a862d0417ccda2bafe55e0d2616d1e1a (diff)
strelka: split out vcfs
Diffstat (limited to 'tools/strelka-call.nix')
-rw-r--r--tools/strelka-call.nix17
1 files changed, 13 insertions, 4 deletions
diff --git a/tools/strelka-call.nix b/tools/strelka-call.nix
index cbdcfb4..e90bdfd 100644
--- a/tools/strelka-call.nix
+++ b/tools/strelka-call.nix
@@ -16,12 +16,14 @@ let
refs = map getref inputs;
ref = head refs;
+ drv = bionix.strelka.call {inherit indexAttrs bamIndexAttrs flags;} inputs;
+
in
assert (length (unique refs) == 1);
stage {
- name = "strelka";
+ name = "strelka-call";
buildInputs = with pkgs; [ strelka ];
buildCommand = ''
ln -s ${ref} ref.fa
@@ -30,14 +32,21 @@ stage {
${concatMapStringsSep "\n" (p: "ln -s ${bionix.samtools.index bamIndexAttrs p} ${filename p}.bai") inputs}
configureStrelkaGermlineWorkflow.py \
- ${concatMapStringsSep " " (i: "--bam ${filename i}.bam") inputs} \
+ ${concatMapStringsSep " " (i: "--bam ${filename i}.bam") inputs} \
--ref ref.fa \
--runDir $TMPDIR
./runWorkflow.py \
-m local \
- -j $NIX_BUILD_CORES
+ -j $NIX_BUILD_CORES 2>&1
cp -r results $out
- '';
+ '';
+ passthru.variants = stage {
+ name = "strelka-call-variants";
+ buildCommand = ''
+ ln -s ${drv}/variants/variants.vcf.gz $out
+ '';
+ passthru.filetype = filetype.gz (filetype.vcf {ref=ref;});
+ };
}