Skip to content

Commit

Permalink
Index fails when FASTAs have different line len
Browse files Browse the repository at this point in the history
Fixes #52
  • Loading branch information
MarieLataretu committed Feb 18, 2022
1 parent 32693f5 commit c14c5d2
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion modules/get_host.nf
Original file line number Diff line number Diff line change
Expand Up @@ -56,11 +56,12 @@ process check_own {
"""
# -L for following a symbolic link
if ! ( file -L $fasta | grep -q 'gzip compressed' ); then
sed -i -e '\$a\\' ${fasta}
bgzip -@ ${task.cpus} < ${fasta} > ${fasta}.gz
# now $fasta'.gz'
else
mv ${fasta} ${fasta}.tmp
zcat ${fasta}.tmp | bgzip -@ ${task.cpus} -c > ${fasta}.gz
zcat ${fasta}.tmp | sed -e '\$a\\' | bgzip -@ ${task.cpus} -c > ${fasta}.gz
fi
"""
}
Expand Down

0 comments on commit c14c5d2

Please sign in to comment.