Skip to content

Commit

Permalink
Merge pull request nf-core#1541 from asp8200/fix_1540
Browse files Browse the repository at this point in the history
Getting mapped bam and bai published in the same folder
  • Loading branch information
maxulysse authored May 27, 2024
2 parents c5a9ca0 + 01fe57d commit 76367cc
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Fixed

- [#1541](https://github.com/nf-core/sarek/pull/1541) - Getting bam and bai published in the same folder
- [#1542](https://github.com/nf-core/sarek/pull/1542) - Removing legacy configs of `CUSTOM_DUMPSOFTWAREVERSIONS`

### Removed
Expand Down
6 changes: 6 additions & 0 deletions workflows/sarek/main.nf
Original file line number Diff line number Diff line change
Expand Up @@ -253,6 +253,12 @@ workflow SAREK {
}
.set { reads_grouping_key }

reads_for_alignment = reads_for_alignment.map{ meta, reads ->
// Update meta.id to meta.sample no multiple lanes or splitted fastqs
if (meta.size * meta.num_lanes == 1) [ meta + [ id:meta.sample ], reads ]
else [ meta, reads ]
}

// reads will be sorted
sort_bam = true
FASTQ_ALIGN_BWAMEM_MEM2_DRAGMAP_SENTIEON(reads_for_alignment, index_alignment, sort_bam, fasta, fasta_fai)
Expand Down

0 comments on commit 76367cc

Please sign in to comment.