nextflow-io / nextflow-io/nextflow
docs on using closure for `path` param in publishDir
Nobody has claimed this yet.
- Dominant language
- Groovy
- Stars
- 3.5k
- Forks
- 811
- Avg merge
- 2d 11h
- Merged PRs (30d)
- 61
Description
New feature
The publishDir docs do not state that a closure is needed for the path parameter if a nextflow parameter is used.
My case:
profiles {
dev {
params {
outdir_prefix = 'tmp/results'
}
}
process{
withName: 'STAR_map' {
publishDir = [
mode: 'copy',
overwrite: true,
path: { params.outdir_prefix },
pattern: '*'
]
}
}
Without the closure ({ params.outdir_prefix }), I get the error:
Target path for directive publishDir cannot be null
It took quite a bit of time to figure out that a closure is needed.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the publishDir documentation section linked in the issue and review the provided configuration example showing params.outdir_prefix. Update the documentation to explain when the path parameter requires a closure, using the reported null-target-path behavior as context; done means users can find this guidance there.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- groovy
- Domain
- documentation
- Issue type
- Documentation
- Difficulty
- 1/5
- Estimated time
- Under an hour
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 45/100