blob: 7c62bdc6ae4dd312c5ea05264532f4ca70907b85 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
{ bionix
, mateScore ? true
, flags ? null
}:
input:
with bionix;
with lib;
with types;
assert (matchFiletype "samtools-fixmate" { bam = _: true; } input);
assert (matchFileSorting "samtools-fixmate" { name = _: true; } input);
stage {
name = "samtools-fixmate";
buildInputs = with pkgs; [ samtools ];
buildCommand = ''
samtools fixmate \
${optionalString mateScore "-m"} \
${optionalString (flags != null) flags} -O bam ${input} $out
'';
passthru.filetype = input.filetype;
}
|