I am developing a pipeline that uses the nf-core module star_align. According to the code, I can provide extra arguments through the task.ext.args process property. According to the documentation, one way of doing this is to provide them on my modules.config file, for instance:
This approach, however, provides the same argument for every single execution of the STAR_ALIGN process. My question is: what if I want to execute the STAR_ALIGN process again but with different arguments?
Update 1:
Maybe it is worth mentioning that I am calling the STAR_ALIGN multiple times on my pipeline, and every execution is wrapped around its own subworkflow process. So, if there is a way to provide the task.ext.args per subworkflow, it would work.
There are two ways in which you might solve this issue:
Option 1 - Full Names
If your example, you’re providing the process name STAR_ALIGN to the withName selector. To differentiate between STAR_ALIGN processes inside different subworkflows, you can use the full qualified name:
Option 2 - Uniquely Named Imports
Alternatively, you can import one or more of the STAR_ALIGN processes using a unique name, and use that new name in the withName selector:
include { STAR_ALIGN as STAR_PER_GENE } from './modules/local/star'
include { STAR_ALIGN as STAR_TRANSCRIPTS } from './modules/local/star'