aboutsummaryrefslogtreecommitdiff
path: root/tools/mosdepth-depth.nix
diff options
context:
space:
mode:
authorJustin Bedo <cu@cua0.org>2018-10-04 12:06:54 +1000
committerJustin Bedo <cu@cua0.org>2018-10-04 12:06:54 +1000
commitfe68926931b280aaf29808566b49b2e704e8556a (patch)
treedad0e9e11852e161c87ea6b7f4f6100a5180b9f2 /tools/mosdepth-depth.nix
parent51f3817ecd2ad099b951d11e55eb3e2c516174d3 (diff)
Refactor to use bionix tree directly
Diffstat (limited to 'tools/mosdepth-depth.nix')
-rw-r--r--tools/mosdepth-depth.nix14
1 files changed, 7 insertions, 7 deletions
diff --git a/tools/mosdepth-depth.nix b/tools/mosdepth-depth.nix
index be28aaf..7043c43 100644
--- a/tools/mosdepth-depth.nix
+++ b/tools/mosdepth-depth.nix
@@ -1,10 +1,10 @@
-{ stdenv
-, lib
-, callPackage
-, mosdepth
-, index ? callPackage ./samtools-index.nix {}
-, flags ? null}:
+{ bionix
+, nixpkgs
+, indexAttrs ? {}
+, flags ? null
+}:
+with nixpkgs;
with lib;
input:
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
buildCommand = ''
mkdir $out
ln -s ${input} input.bam
- ln -s ${index input} input.bam.bai
+ ln -s ${bionix.samtools.index indexAttrs input} input.bam.bai
mosdepth -t $NIX_BUILD_CORES ${optionalString (flags != null) flags} $out/out input.bam
'';
}