Skip to content

Commit

Permalink
Returns mapping to nfcore version 2.5.1
Browse files Browse the repository at this point in the history
  • Loading branch information
cgpu committed Dec 12, 2019
1 parent 3fcf68a commit 30a14e2
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -675,16 +675,9 @@ process MapReads {
convertToFastq = hasExtension(inputFile1, "bam") ? "gatk --java-options -Xmx${task.memory.toGiga()}g SamToFastq --INPUT=${inputFile1} --FASTQ=/dev/stdout --INTERLEAVE=true --NON_PF=true | \\" : ""
input = hasExtension(inputFile1, "bam") ? "-p /dev/stdin - 2> >(tee ${inputFile1}.bwa.stderr.log >&2)" : "${inputFile1} ${inputFile2}"
"""
# map to sam
${convertToFastq}
bwa mem -K 100000000 -R \"${readGroup}\" ${extra} -t ${task.cpus} -M ${fasta} \
${input} > ${idSample}_${idRun}.sam
# create bam
samtools view -@ ${task.cpus} -b -h -O BAM -o ${idSample}_${idRun}.bwamem.bam ${idSample}_${idRun}.sam
# sort bam
samtools sort -@ ${task.cpus} -o ${idSample}_${idRun}.bam
${input} | samtools sort - > ${idSample}_${idRun}.bam
"""
}

Expand Down

0 comments on commit 30a14e2

Please sign in to comment.