diff --git a/modules/local/index_creation.nf b/modules/local/index_creation.nf new file mode 100644 index 0000000..adfe58e --- /dev/null +++ b/modules/local/index_creation.nf @@ -0,0 +1,16 @@ +process INDEX_CREATION { + input: + path reference + val mtdna_tag + + output: + path "ref*.{dict,fai}", emit: fasta_index_ch + path "ref.fasta", emit: ref_ch + + """ + sed -e "s/^>.*/>$mtdna_tag/" $reference > ref.fasta + samtools faidx ref.fasta + samtools dict ref.fasta \ + -o ref.dict + """ +} \ No newline at end of file