aboutsummaryrefslogtreecommitdiff
path: root/tools/kallisto-index.nix
blob: 33dfb805bfb933415efa542e552a509b61abe8c0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
{bionix
, nixpkgs
, kmerSize ? 31
, unique ? false}:

with nixpkgs;
with lib;
with bionix.types;

assert (kmerSize > 1);

input:

assert (matchFiletype input { fa = _: true; } input);

stdenv.mkDerivation {
  name = "kallisto-index";
  buildInputs = [ kallisto ];
  buildCommand = ''
    kallisto index -k ${toString kmerSize} ${optionalString unique "--make-unique"} -i $out ${input}
  '';
}