diff options
author | Justin Bedo <cu@cua0.org> | 2018-09-20 13:57:12 +1000 |
---|---|---|
committer | Justin Bedo <cu@cua0.org> | 2018-09-20 14:34:36 +1000 |
commit | 33a121a7bad5b2608cc41ce60ab3d65676541fa6 (patch) | |
tree | dbbce4154a85988f3bfd9b13d42ad5d37f04e18a /tools/samtools-sort.nix | |
parent | f0a8a4de59ea79f56e074ddd16eff0ce1782dfe8 (diff) |
Wrap some tools and make an example pipeline
Diffstat (limited to 'tools/samtools-sort.nix')
-rw-r--r-- | tools/samtools-sort.nix | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/tools/samtools-sort.nix b/tools/samtools-sort.nix new file mode 100644 index 0000000..1a79c9f --- /dev/null +++ b/tools/samtools-sort.nix @@ -0,0 +1,19 @@ +{ stdenv +, callPackage +, lib +, samtools +, nameSort ? false +, flags ? null +}: + +input: + +with lib; + +stdenv.mkDerivation { + name = "samtools-sort"; + buildInputs = [ samtools ]; + buildCommand = '' + samtools sort -@ $NIX_BUILD_CORES ${optionalString nameSort "-n"} ${optionalString (flags != null) flags} ${input} > $out + ''; +} |