From b9637aab8e21fa9b716c691352aa44cd1bc43ead Mon Sep 17 00:00:00 2001 From: ejseqera Date: Sun, 17 Nov 2024 17:33:00 -0500 Subject: [PATCH] Add context for projectDir after first introduction --- docs/hello_nextflow/04_hello_genomics.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/docs/hello_nextflow/04_hello_genomics.md b/docs/hello_nextflow/04_hello_genomics.md index 64252116..e533e618 100644 --- a/docs/hello_nextflow/04_hello_genomics.md +++ b/docs/hello_nextflow/04_hello_genomics.md @@ -220,6 +220,12 @@ params.reads_bam = "${projectDir}/data/bam/reads_mother.bam" Now we have a process ready, as well as a parameter to give it an input to run on, so let's wire those things up together. +!!! note + + `${projectDir}` is a built-in Nextflow variable that points to the directory where the current Nextflow workflow script (`hello-genomics.nf`) is located. + + This makes it easy to reference files, data directories, and other resources included in the workflow repository without hardcoding absolute paths. + ### 1.3. Add workflow block to run SAMTOOLS_INDEX In the `workflow` block, we need to set up a **channel** to feed the input to the `SAMTOOLS_INDEX` process; then we can call the process itself to run on the contents of that channel.