diff options
Diffstat (limited to 'tools/snap-index.nix')
-rw-r--r-- | tools/snap-index.nix | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/tools/snap-index.nix b/tools/snap-index.nix new file mode 100644 index 0000000..b72ee01 --- /dev/null +++ b/tools/snap-index.nix @@ -0,0 +1,22 @@ +{ bionix +, flags ? null +}: + +ref: + +with bionix; +with lib; +with types; + +assert (matchFiletype "snap-index" { fa = _: true; } ref); + +stage { + name = "snap-index"; + buildInputs = [ bionix.snap.app ]; + buildCommand = '' + ln -s ${ref} ref.fa + mkdir $out + snap-aligner index ref.fa $out -t$NIX_BUILD_CORES ${optionalString (flags != null) flags} + ''; + passthru.multicore = true; +} |