From 60be311d98b57080127bc8cc13a8c9741c793322 Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Wed, 20 Nov 2024 12:05:55 -0600 Subject: [PATCH 01/23] ci: Fix linting getting skipped --- .github/workflows/lint.yml | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 756894a27b0..cc50b50488a 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -61,14 +61,20 @@ jobs: - uses: dorny/paths-filter@de90cc6fb38fc0963ad72b210f1f284cd68cea36 # v3 id: filter with: - filters: "tests/config/pytest_modules.yml" + filters: | + modules: + - 'modules/nf-core/**' + - 'tests/modules/nf-core/**' + subworkflows: + - 'subworkflows/nf-core/**' + - 'tests/subworkflows/nf-core/**' token: "" - name: Fetch module tags id: tags run: | - echo modules=$(echo '${{ steps.filter.outputs.changes }}' | jq -c '. | map(select(contains("modules"))) | map(gsub("modules/"; ""))') >> $GITHUB_OUTPUT - echo subworkflows=$(echo '${{ steps.filter.outputs.changes }}' | jq '. | map(select(contains("subworkflow"))) | map(gsub("subworkflows/"; ""))') >> $GITHUB_OUTPUT + echo "modules=${{ steps.filter.outputs.modules }}" >> $GITHUB_OUTPUT + echo "subworkflows=${{ steps.filter.outputs.subworkflows }}" >> $GITHUB_OUTPUT - name: debug run: | From 8a17d610509b541b1dfed5c017d314a4d27ddbff Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Wed, 20 Nov 2024 12:13:32 -0600 Subject: [PATCH 02/23] ci: Add list-files json --- .github/workflows/lint.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index cc50b50488a..4c6f01d4e7a 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -69,6 +69,7 @@ jobs: - 'subworkflows/nf-core/**' - 'tests/subworkflows/nf-core/**' token: "" + list-files: "json" - name: Fetch module tags id: tags From be45e46bcdb1a003785d50cc05cd4c2021cbaaa6 Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Wed, 20 Nov 2024 12:16:18 -0600 Subject: [PATCH 03/23] ci: Why do we need a Docker container again? --- .github/actions/self-hosted-cleanup/Dockerfile | 7 ------- .github/actions/self-hosted-cleanup/README.md | 1 - .github/actions/self-hosted-cleanup/action.yml | 9 --------- .../cleanup-selfhosted-runner.bash} | 0 .github/workflows/gpu-tests.yml | 2 +- .github/workflows/nf-test.yml | 4 ++-- 6 files changed, 3 insertions(+), 20 deletions(-) delete mode 100644 .github/actions/self-hosted-cleanup/Dockerfile delete mode 100644 .github/actions/self-hosted-cleanup/README.md delete mode 100644 .github/actions/self-hosted-cleanup/action.yml rename .github/{actions/self-hosted-cleanup/entrypoint.sh => scripts/cleanup-selfhosted-runner.bash} (100%) diff --git a/.github/actions/self-hosted-cleanup/Dockerfile b/.github/actions/self-hosted-cleanup/Dockerfile deleted file mode 100644 index 1a927fbc9d1..00000000000 --- a/.github/actions/self-hosted-cleanup/Dockerfile +++ /dev/null @@ -1,7 +0,0 @@ -FROM quay.io/nf-core/ubuntu - -# Copies your code file from your action repository to the filesystem path `/` of the container -COPY entrypoint.sh /entrypoint.sh - -# Code file to execute when the docker container starts up (`entrypoint.sh`) -ENTRYPOINT ["/entrypoint.sh"] diff --git a/.github/actions/self-hosted-cleanup/README.md b/.github/actions/self-hosted-cleanup/README.md deleted file mode 100644 index 4d6282f2ffd..00000000000 --- a/.github/actions/self-hosted-cleanup/README.md +++ /dev/null @@ -1 +0,0 @@ -Copied from https://github.com/AutoModality/action-clean diff --git a/.github/actions/self-hosted-cleanup/action.yml b/.github/actions/self-hosted-cleanup/action.yml deleted file mode 100644 index 350566c3ec4..00000000000 --- a/.github/actions/self-hosted-cleanup/action.yml +++ /dev/null @@ -1,9 +0,0 @@ -# see package.yml for usage -name: 'Clean Workspace' -description: 'Deletes all files in the work directory.' -runs: - using: 'docker' - image: 'Dockerfile' -branding: - icon: delete - color: red diff --git a/.github/actions/self-hosted-cleanup/entrypoint.sh b/.github/scripts/cleanup-selfhosted-runner.bash similarity index 100% rename from .github/actions/self-hosted-cleanup/entrypoint.sh rename to .github/scripts/cleanup-selfhosted-runner.bash diff --git a/.github/workflows/gpu-tests.yml b/.github/workflows/gpu-tests.yml index 2a60044b22b..fa1b1f9f945 100644 --- a/.github/workflows/gpu-tests.yml +++ b/.github/workflows/gpu-tests.yml @@ -49,7 +49,7 @@ jobs: # Prod for version bumping steps: - name: Clean Workspace # Purge the workspace in case it's running on a self-hosted runner - uses: ./.github/actions/self-hosted-cleanup + run: ./.github/scriptscleanup-selfhosted-runner.bash - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 with: fetch-depth: 0 diff --git a/.github/workflows/nf-test.yml b/.github/workflows/nf-test.yml index 303f121a7d4..4a8ef0bc5a4 100644 --- a/.github/workflows/nf-test.yml +++ b/.github/workflows/nf-test.yml @@ -63,7 +63,7 @@ jobs: SENTIEON_ENCRYPTION_KEY: ${{ secrets.SENTIEON_ENCRYPTION_KEY }} steps: - name: Clean Workspace # Purge the workspace in case it's running on a self-hosted runner - uses: ./.github/actions/self-hosted-cleanup + run: ./.github/scriptscleanup-selfhosted-runner.bash - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 with: fetch-depth: 0 @@ -74,4 +74,4 @@ jobs: shard: ${{ matrix.shard }} total_shards: ${{ env.TOTAL_SHARDS }} - name: Clean Workspace # Purge the workspace in case it's running on a self-hosted runner - uses: ./.github/actions/self-hosted-cleanup + run: ./.github/scriptscleanup-selfhosted-runner.bash From 1aac9245fd72d3860fe3e641a7307a8decdbb78e Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Wed, 20 Nov 2024 12:23:42 -0600 Subject: [PATCH 04/23] ci: Can't use a script if it doesn't exist yet Co-authored-by: adamrtalbot --- .github/actions/nf-test-action/action.yml | 8 ++++++++ .github/scripts/cleanup-selfhosted-runner.bash | 8 -------- .github/workflows/gpu-tests.yml | 6 +++++- .github/workflows/nf-test.yml | 8 +++++--- 4 files changed, 18 insertions(+), 12 deletions(-) delete mode 100644 .github/scripts/cleanup-selfhosted-runner.bash diff --git a/.github/actions/nf-test-action/action.yml b/.github/actions/nf-test-action/action.yml index 1fdfcd83a98..015b92cb8a0 100644 --- a/.github/actions/nf-test-action/action.yml +++ b/.github/actions/nf-test-action/action.yml @@ -98,3 +98,11 @@ runs: shell: bash run: | sudo rm -rf /home/ubuntu/tests/ + + - name: Clean Workspace # Purge the workspace in case it's running on a self-hosted runner + if: always() + run: | + ls -la ./ + rm -rf ./* || true + rm -rf ./.??* || true + ls -la ./ diff --git a/.github/scripts/cleanup-selfhosted-runner.bash b/.github/scripts/cleanup-selfhosted-runner.bash deleted file mode 100644 index 368ebf922d0..00000000000 --- a/.github/scripts/cleanup-selfhosted-runner.bash +++ /dev/null @@ -1,8 +0,0 @@ -#!/usr/bin/env bash - -set -e # fail on error - -# include hidden files -# https://askubuntu.com/questions/740805/how-can-i-remove-all-files-from-current-directory-using-terminal -shopt -s dotglob -rm -rf * diff --git a/.github/workflows/gpu-tests.yml b/.github/workflows/gpu-tests.yml index fa1b1f9f945..a3152915162 100644 --- a/.github/workflows/gpu-tests.yml +++ b/.github/workflows/gpu-tests.yml @@ -49,7 +49,11 @@ jobs: # Prod for version bumping steps: - name: Clean Workspace # Purge the workspace in case it's running on a self-hosted runner - run: ./.github/scriptscleanup-selfhosted-runner.bash + run: | + ls -la ./ + rm -rf ./* || true + rm -rf ./.??* || true + ls -la ./ - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 with: fetch-depth: 0 diff --git a/.github/workflows/nf-test.yml b/.github/workflows/nf-test.yml index 4a8ef0bc5a4..5445a444531 100644 --- a/.github/workflows/nf-test.yml +++ b/.github/workflows/nf-test.yml @@ -63,7 +63,11 @@ jobs: SENTIEON_ENCRYPTION_KEY: ${{ secrets.SENTIEON_ENCRYPTION_KEY }} steps: - name: Clean Workspace # Purge the workspace in case it's running on a self-hosted runner - run: ./.github/scriptscleanup-selfhosted-runner.bash + run: | + ls -la ./ + rm -rf ./* || true + rm -rf ./.??* || true + ls -la ./ - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 with: fetch-depth: 0 @@ -73,5 +77,3 @@ jobs: profile: ${{ matrix.profile }} shard: ${{ matrix.shard }} total_shards: ${{ env.TOTAL_SHARDS }} - - name: Clean Workspace # Purge the workspace in case it's running on a self-hosted runner - run: ./.github/scriptscleanup-selfhosted-runner.bash From baf417fe63993b21c545b8e06ef97f4d973bd197 Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Wed, 20 Nov 2024 12:35:40 -0600 Subject: [PATCH 05/23] ci: Skip outputs if they're empty --- .github/workflows/lint.yml | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 4c6f01d4e7a..5b48664894a 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -72,15 +72,21 @@ jobs: list-files: "json" - name: Fetch module tags - id: tags + id: module-tags + if: steps.filter.outputs.modules == 'true' run: | echo "modules=${{ steps.filter.outputs.modules }}" >> $GITHUB_OUTPUT + + - name: Fetch subworkflows tags + id: subworkflow-tags + if: steps.filter.outputs.subworkflows == 'true' + run: | echo "subworkflows=${{ steps.filter.outputs.subworkflows }}" >> $GITHUB_OUTPUT - name: debug run: | - echo ${{ steps.tags.outputs.modules }} - echo ${{ steps.tags.outputs.subworkflows }} + echo ${{ steps.module-tags.outputs.modules }} + echo ${{ steps.subworkflow-tags.outputs.subworkflows }} nf-core-lint-modules: runs-on: ${{ github.event.inputs.runners || 'self-hosted' }} From da64fcefcade0b863c59055e1c0a429d73cebff4 Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Wed, 20 Nov 2024 12:47:01 -0600 Subject: [PATCH 06/23] style: Run lsp on fastqc --- modules/nf-core/fastqc/main.nf | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/modules/nf-core/fastqc/main.nf b/modules/nf-core/fastqc/main.nf index d8989f48122..1a59b73e709 100644 --- a/modules/nf-core/fastqc/main.nf +++ b/modules/nf-core/fastqc/main.nf @@ -1,19 +1,19 @@ process FASTQC { - tag "$meta.id" + tag "${meta.id}" label 'process_medium' conda "${moduleDir}/environment.yml" - container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity/fastqc:0.12.1--hdfd78af_0' : - 'biocontainers/fastqc:0.12.1--hdfd78af_0' }" + container "${workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container + ? 'https://depot.galaxyproject.org/singularity/fastqc:0.12.1--hdfd78af_0' + : 'biocontainers/fastqc:0.12.1--hdfd78af_0'}" input: tuple val(meta), path(reads) output: tuple val(meta), path("*.html"), emit: html - tuple val(meta), path("*.zip") , emit: zip - path "versions.yml" , emit: versions + tuple val(meta), path("*.zip"), emit: zip + path "versions.yml", emit: versions when: task.ext.when == null || task.ext.when @@ -22,9 +22,9 @@ process FASTQC { def args = task.ext.args ?: '' def prefix = task.ext.prefix ?: "${meta.id}" // Make list of old name and new name pairs to use for renaming in the bash while loop - def old_new_pairs = reads instanceof Path || reads.size() == 1 ? [[ reads, "${prefix}.${reads.extension}" ]] : reads.withIndex().collect { entry, index -> [ entry, "${prefix}_${index + 1}.${entry.extension}" ] } - def rename_to = old_new_pairs*.join(' ').join(' ') - def renamed_files = old_new_pairs.collect{ old_name, new_name -> new_name }.join(' ') + def old_new_pairs = reads instanceof Path || reads.size() == 1 ? [[reads, "${prefix}.${reads.extension}"]] : reads.withIndex().collect { entry, index -> [entry, "${prefix}_${index + 1}.${entry.extension}"] } + def rename_to = old_new_pairs.join(' ').join(' ') + def renamed_files = old_new_pairs.collect { old_name, new_name -> new_name }.join(' ') // The total amount of allocated RAM by FastQC is equal to the number of threads defined (--threads) time the amount of RAM defined (--memory) // https://github.com/s-andrews/FastQC/blob/1faeea0412093224d7f6a07f777fad60a5650795/fastqc#L211-L222 @@ -34,15 +34,15 @@ process FASTQC { def fastqc_memory = memory_in_mb > 10000 ? 10000 : (memory_in_mb < 100 ? 100 : memory_in_mb) """ - printf "%s %s\\n" $rename_to | while read old_name new_name; do + printf "%s %s\\n" ${rename_to} | while read old_name new_name; do [ -f "\${new_name}" ] || ln -s \$old_name \$new_name done fastqc \\ - $args \\ - --threads $task.cpus \\ - --memory $fastqc_memory \\ - $renamed_files + ${args} \\ + --threads ${task.cpus} \\ + --memory ${fastqc_memory} \\ + ${renamed_files} cat <<-END_VERSIONS > versions.yml "${task.process}": From 36c711ec0a5be095749327a1a1ff6e549b39802a Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Wed, 20 Nov 2024 12:57:42 -0600 Subject: [PATCH 07/23] ci: Use files to skip extra steps --- .github/workflows/lint.yml | 32 +++++++++++--------------------- 1 file changed, 11 insertions(+), 21 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 5b48664894a..2ef75c27e04 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -50,9 +50,11 @@ jobs: name: nf-core-changes runs-on: ubuntu-latest outputs: - tags: ${{ steps.filter.outputs.changes }} - modules: ${{ steps.tags.outputs.modules }} - subworkflows: ${{ steps.tags.outputs.subworkflows }} + # https://github.com/dorny/paths-filter?tab=readme-ov-file#custom-processing-of-changed-files + modules: ${{ steps.filter.outputs.modules }} + modules_files: ${{ steps.filter.outputs.modules_files }} + subworkflows: ${{ steps.filter.outputs.subworkflows}} + subworkflows_files: ${{ steps.filter.outputs.subworkflows_files }} steps: - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4 with: @@ -71,32 +73,20 @@ jobs: token: "" list-files: "json" - - name: Fetch module tags - id: module-tags - if: steps.filter.outputs.modules == 'true' - run: | - echo "modules=${{ steps.filter.outputs.modules }}" >> $GITHUB_OUTPUT - - - name: Fetch subworkflows tags - id: subworkflow-tags - if: steps.filter.outputs.subworkflows == 'true' - run: | - echo "subworkflows=${{ steps.filter.outputs.subworkflows }}" >> $GITHUB_OUTPUT - - name: debug run: | - echo ${{ steps.module-tags.outputs.modules }} - echo ${{ steps.subworkflow-tags.outputs.subworkflows }} + echo ${{ steps.filter.outputs.modules_files }} + echo ${{ steps.filter.outputs.subworkflows_files }} nf-core-lint-modules: runs-on: ${{ github.event.inputs.runners || 'self-hosted' }} name: nf-core lint modules needs: nf-core-changes - if: ${{ (needs.nf-core-changes.outputs.modules != '[]') }} + if: ${{ (needs.nf-core-changes.outputs.modules == 'true') }} strategy: fail-fast: false matrix: - tags: "${{ fromJson(needs.nf-core-changes.outputs.modules) }}" + tags: "${{ fromJson(needs.nf-core-changes.outputs.modules_files) }}" steps: - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4 @@ -134,11 +124,11 @@ jobs: runs-on: ubuntu-latest name: nf-core lint subworkflows needs: nf-core-changes - if: ${{ (needs.nf-core-changes.outputs.subworkflows != '[]') }} + if: ${{ (needs.nf-core-changes.outputs.subworkflows == 'true') }} strategy: fail-fast: false matrix: - tags: "${{ fromJson(needs.nf-core-changes.outputs.subworkflows) }}" + tags: "${{ fromJson(needs.nf-core-changes.outputs.subworkflows_files) }}" steps: - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4 From 7f4eb68598e2faad2d4dd1249681a5998dcec557 Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Wed, 20 Nov 2024 13:07:43 -0600 Subject: [PATCH 08/23] ci(lint): Get the module name https://github.com/nf-core/tools/pull/3141 --- .github/workflows/lint.yml | 28 ++++++++++++++++++++++------ 1 file changed, 22 insertions(+), 6 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 2ef75c27e04..8298448674c 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -86,7 +86,7 @@ jobs: strategy: fail-fast: false matrix: - tags: "${{ fromJson(needs.nf-core-changes.outputs.modules_files) }}" + files: "${{ fromJson(needs.nf-core-changes.outputs.modules_files) }}" steps: - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4 @@ -117,8 +117,16 @@ jobs: - name: Install nf-core tools development version run: python -m pip install --upgrade --force-reinstall git+https://github.com/nf-core/tools.git@dev - - name: Lint module ${{ matrix.tags }} - run: nf-core modules lint ${{ matrix.tags }} + - name: Get module name + uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7 + id: name + with: + result-encoding: string + script: | + return '${{ matrix.files }}'.replace('modules/nf-core/', '').replace('/main.nf', ''); + + - name: Lint module ${{steps.name.outputs.result}} + run: nf-core modules lint ${{steps.name.outputs.result}} nf-core-lint-subworkflows: runs-on: ubuntu-latest @@ -128,7 +136,7 @@ jobs: strategy: fail-fast: false matrix: - tags: "${{ fromJson(needs.nf-core-changes.outputs.subworkflows_files) }}" + files: "${{ fromJson(needs.nf-core-changes.outputs.subworkflows_files) }}" steps: - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4 @@ -151,8 +159,16 @@ jobs: - name: Install nf-core tools development version run: python -m pip install --upgrade --force-reinstall git+https://github.com/nf-core/tools.git@dev - - name: Lint module ${{ matrix.tags }} - run: nf-core subworkflows lint ${{ matrix.tags }} + - name: Get module name + uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7 + id: name + with: + result-encoding: string + script: | + return '${{ matrix.files }}'.replace('modules/nf-core/', '').replace('/main.nf', ''); + + - name: Lint subworkflow ${{steps.name.outputs.result}} + run: nf-core subworkflows lint ${{steps.name.outputs.result}} confirm-pass: runs-on: ubuntu-latest From 1961d891da1a19be62ec4229e81926aa6e4bee51 Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Wed, 20 Nov 2024 13:45:29 -0600 Subject: [PATCH 09/23] ci: Add what shell to run on --- .github/actions/nf-test-action/action.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/actions/nf-test-action/action.yml b/.github/actions/nf-test-action/action.yml index 015b92cb8a0..d3b0bb3e469 100644 --- a/.github/actions/nf-test-action/action.yml +++ b/.github/actions/nf-test-action/action.yml @@ -101,6 +101,7 @@ runs: - name: Clean Workspace # Purge the workspace in case it's running on a self-hosted runner if: always() + shell: bash run: | ls -la ./ rm -rf ./* || true From 18f7965b0b62dd2306bb2c150d45e1738400ee7c Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Wed, 20 Nov 2024 13:50:42 -0600 Subject: [PATCH 10/23] ci: Clean up the names in the filter step --- .github/workflows/lint.yml | 36 +++++++++++++++++------------------- 1 file changed, 17 insertions(+), 19 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 8298448674c..2c9067c7337 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -52,9 +52,9 @@ jobs: outputs: # https://github.com/dorny/paths-filter?tab=readme-ov-file#custom-processing-of-changed-files modules: ${{ steps.filter.outputs.modules }} - modules_files: ${{ steps.filter.outputs.modules_files }} - subworkflows: ${{ steps.filter.outputs.subworkflows}} - subworkflows_files: ${{ steps.filter.outputs.subworkflows_files }} + modules_files: ${{ steps.module-names.outputs.results }} + subworkflows: ${{ steps.filter.outputs.subworkflows }} + subworkflows_files: ${{ steps.subworkflow-names.outputs.results }} steps: - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4 with: @@ -73,6 +73,20 @@ jobs: token: "" list-files: "json" + - name: Get module name + uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7 + id: modules-names + with: + script: | + return '${{ steps.filter.outputs.modules_files }}'.replace('modules/nf-core/', '').replace('/main.nf', ''); + + - name: Get module name + uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7 + id: subworkflow-names + with: + script: | + return '${{ steps.filter.outputs.subworkflow_files }}'.replace('modules/nf-core/', '').replace('/main.nf', ''); + - name: debug run: | echo ${{ steps.filter.outputs.modules_files }} @@ -117,14 +131,6 @@ jobs: - name: Install nf-core tools development version run: python -m pip install --upgrade --force-reinstall git+https://github.com/nf-core/tools.git@dev - - name: Get module name - uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7 - id: name - with: - result-encoding: string - script: | - return '${{ matrix.files }}'.replace('modules/nf-core/', '').replace('/main.nf', ''); - - name: Lint module ${{steps.name.outputs.result}} run: nf-core modules lint ${{steps.name.outputs.result}} @@ -159,14 +165,6 @@ jobs: - name: Install nf-core tools development version run: python -m pip install --upgrade --force-reinstall git+https://github.com/nf-core/tools.git@dev - - name: Get module name - uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7 - id: name - with: - result-encoding: string - script: | - return '${{ matrix.files }}'.replace('modules/nf-core/', '').replace('/main.nf', ''); - - name: Lint subworkflow ${{steps.name.outputs.result}} run: nf-core subworkflows lint ${{steps.name.outputs.result}} From c57d27f754682a916ab0c2d893df36d7eaa189e2 Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Wed, 20 Nov 2024 15:15:29 -0600 Subject: [PATCH 11/23] ci: Add hack to only lint the real changes --- .github/workflows/lint.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 2c9067c7337..c2c42f5ba4b 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -78,14 +78,14 @@ jobs: id: modules-names with: script: | - return '${{ steps.filter.outputs.modules_files }}'.replace('modules/nf-core/', '').replace('/main.nf', ''); + return '${{ steps.filter.outputs.modules_files }}'.replace('modules/nf-core/', '').replace('/main.nf', '').replace('/environment.yml', '').replace('/meta.yml', '').replace('/README.md', '').replace('/tests/tags.yml', '').replace('/tests/main.nf.test', '').replace('/tests/main.nf.test.snap', ''); - name: Get module name uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7 id: subworkflow-names with: script: | - return '${{ steps.filter.outputs.subworkflow_files }}'.replace('modules/nf-core/', '').replace('/main.nf', ''); + return '${{ steps.filter.outputs.subworkflows_files }}'.replace('subworkflows/nf-core/', '').replace('/main.nf', '').replace('/environment.yml', '').replace('/meta.yml', '').replace('/README.md', '').replace('/tests/tags.yml', '').replace('/tests/main.nf.test', '').replace('/tests/main.nf.test.snap', ''); - name: debug run: | From 776964d9f87e5cabf9ed062e3a49460bafaed5c1 Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Wed, 20 Nov 2024 18:51:27 -0600 Subject: [PATCH 12/23] ci: Add more to debug step --- .github/workflows/lint.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index c2c42f5ba4b..91394088de1 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -80,7 +80,7 @@ jobs: script: | return '${{ steps.filter.outputs.modules_files }}'.replace('modules/nf-core/', '').replace('/main.nf', '').replace('/environment.yml', '').replace('/meta.yml', '').replace('/README.md', '').replace('/tests/tags.yml', '').replace('/tests/main.nf.test', '').replace('/tests/main.nf.test.snap', ''); - - name: Get module name + - name: Get subworkflow name uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7 id: subworkflow-names with: @@ -91,6 +91,8 @@ jobs: run: | echo ${{ steps.filter.outputs.modules_files }} echo ${{ steps.filter.outputs.subworkflows_files }} + echo ${{ steps.module-names.outputs.results }} + echo ${{ steps.subworkflow-names.outputs.results }} nf-core-lint-modules: runs-on: ${{ github.event.inputs.runners || 'self-hosted' }} From 43ac98c1ee7a7027438f9b561390968dce2c395e Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Wed, 20 Nov 2024 19:09:46 -0600 Subject: [PATCH 13/23] ci(lint): Get fancy with map --- .github/workflows/lint.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 91394088de1..5e3630cf8e8 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -78,14 +78,14 @@ jobs: id: modules-names with: script: | - return '${{ steps.filter.outputs.modules_files }}'.replace('modules/nf-core/', '').replace('/main.nf', '').replace('/environment.yml', '').replace('/meta.yml', '').replace('/README.md', '').replace('/tests/tags.yml', '').replace('/tests/main.nf.test', '').replace('/tests/main.nf.test.snap', ''); + return [...new Set('${{ steps.filter.outputs.modules_files }}'.split(',').map(path => path.replace('modules/nf-core/', '').split('/')[0]))].join(','); - name: Get subworkflow name uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7 id: subworkflow-names with: script: | - return '${{ steps.filter.outputs.subworkflows_files }}'.replace('subworkflows/nf-core/', '').replace('/main.nf', '').replace('/environment.yml', '').replace('/meta.yml', '').replace('/README.md', '').replace('/tests/tags.yml', '').replace('/tests/main.nf.test', '').replace('/tests/main.nf.test.snap', ''); + return [...new Set('${{ steps.filter.outputs.subworkflow_files }}'.split(',').map(path => path.replace('subworkflows/nf-core/', '').split('/')[0]))].join(','); - name: debug run: | From d148c14b946f1de438260617ba6425f5fa2143a3 Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Wed, 20 Nov 2024 19:22:19 -0600 Subject: [PATCH 14/23] ci: One more time --- .github/workflows/lint.yml | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 5e3630cf8e8..c33803b7014 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -52,9 +52,9 @@ jobs: outputs: # https://github.com/dorny/paths-filter?tab=readme-ov-file#custom-processing-of-changed-files modules: ${{ steps.filter.outputs.modules }} - modules_files: ${{ steps.module-names.outputs.results }} + modules_files: ${{ steps.module_names.outputs.results }} subworkflows: ${{ steps.filter.outputs.subworkflows }} - subworkflows_files: ${{ steps.subworkflow-names.outputs.results }} + subworkflows_files: ${{ steps.subworkflow_names.outputs.results }} steps: - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4 with: @@ -75,24 +75,24 @@ jobs: - name: Get module name uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7 - id: modules-names + id: modules_names with: script: | - return [...new Set('${{ steps.filter.outputs.modules_files }}'.split(',').map(path => path.replace('modules/nf-core/', '').split('/')[0]))].join(','); + return JSON.stringify([...new Set('${{ steps.filter.outputs.modules_files }}'.split(',').map(path => path.replace('modules/nf-core/', '').split('/').slice(0, 2).join('/')))]); - name: Get subworkflow name uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7 - id: subworkflow-names + id: subworkflow_names with: script: | - return [...new Set('${{ steps.filter.outputs.subworkflow_files }}'.split(',').map(path => path.replace('subworkflows/nf-core/', '').split('/')[0]))].join(','); + return JSON.stringify([...new Set('${{ steps.filter.outputs.subworkflows_files }}'.split(',').map(path => path.replace('modules/nf-core/', '').split('/').slice(0, 2).join('/')))]); - name: debug run: | echo ${{ steps.filter.outputs.modules_files }} echo ${{ steps.filter.outputs.subworkflows_files }} - echo ${{ steps.module-names.outputs.results }} - echo ${{ steps.subworkflow-names.outputs.results }} + echo ${{ steps.module_names.outputs.results }} + echo ${{ steps.subworkflow_names.outputs.results }} nf-core-lint-modules: runs-on: ${{ github.event.inputs.runners || 'self-hosted' }} @@ -133,8 +133,8 @@ jobs: - name: Install nf-core tools development version run: python -m pip install --upgrade --force-reinstall git+https://github.com/nf-core/tools.git@dev - - name: Lint module ${{steps.name.outputs.result}} - run: nf-core modules lint ${{steps.name.outputs.result}} + - name: Lint module ${{needs.nf-core-changes.outputs.modules_files}} + run: nf-core modules lint ${{needs.nf-core-changes.outputs.modules_files}} nf-core-lint-subworkflows: runs-on: ubuntu-latest @@ -167,8 +167,8 @@ jobs: - name: Install nf-core tools development version run: python -m pip install --upgrade --force-reinstall git+https://github.com/nf-core/tools.git@dev - - name: Lint subworkflow ${{steps.name.outputs.result}} - run: nf-core subworkflows lint ${{steps.name.outputs.result}} + - name: Lint subworkflow ${{needs.nf-core-changes.outputs.subworkflows_files}} + run: nf-core subworkflows lint ${{needs.nf-core-changes.outputs.subworkflows_files}} confirm-pass: runs-on: ubuntu-latest From 2a054ffa7df0c2b7c0bf057423ad2db056afb02e Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Wed, 20 Nov 2024 20:05:24 -0600 Subject: [PATCH 15/23] ci: Maybe? --- .github/workflows/lint.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index c33803b7014..fff1a5567ee 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -78,14 +78,14 @@ jobs: id: modules_names with: script: | - return JSON.stringify([...new Set('${{ steps.filter.outputs.modules_files }}'.split(',').map(path => path.replace('modules/nf-core/', '').split('/').slice(0, 2).join('/')))]); + return ${{ steps.filter.outputs.modules_files }}.map(path => path.replace('modules/nf-core/', '').split('/').slice(0,2).filter(x => x !== 'main.nf').join('/')); - name: Get subworkflow name uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7 id: subworkflow_names with: script: | - return JSON.stringify([...new Set('${{ steps.filter.outputs.subworkflows_files }}'.split(',').map(path => path.replace('modules/nf-core/', '').split('/').slice(0, 2).join('/')))]); + return ${{ steps.filter.outputs.subworkflows_files }}.map(path => path.replace('modules/nf-core/', '').split('/').slice(0,2).filter(x => x !== 'main.nf').join('/')); - name: debug run: | From 308a204f17610a7eb67d51287fc8facf4e20c266 Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Wed, 20 Nov 2024 20:07:10 -0600 Subject: [PATCH 16/23] ci: results => result --- .github/workflows/lint.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index fff1a5567ee..da16469d823 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -52,9 +52,9 @@ jobs: outputs: # https://github.com/dorny/paths-filter?tab=readme-ov-file#custom-processing-of-changed-files modules: ${{ steps.filter.outputs.modules }} - modules_files: ${{ steps.module_names.outputs.results }} + modules_files: ${{ steps.module_names.outputs.result }} subworkflows: ${{ steps.filter.outputs.subworkflows }} - subworkflows_files: ${{ steps.subworkflow_names.outputs.results }} + subworkflows_files: ${{ steps.subworkflow_names.outputs.result }} steps: - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4 with: @@ -91,8 +91,8 @@ jobs: run: | echo ${{ steps.filter.outputs.modules_files }} echo ${{ steps.filter.outputs.subworkflows_files }} - echo ${{ steps.module_names.outputs.results }} - echo ${{ steps.subworkflow_names.outputs.results }} + echo ${{ steps.module_names.outputs.result }} + echo ${{ steps.subworkflow_names.outputs.result }} nf-core-lint-modules: runs-on: ${{ github.event.inputs.runners || 'self-hosted' }} From cac21b9b446aed1be9d3c4a6a0046b18df51a487 Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Wed, 20 Nov 2024 20:08:44 -0600 Subject: [PATCH 17/23] ci: Death by a thousand s's --- .github/workflows/lint.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index da16469d823..2d3ff2a94b1 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -75,7 +75,7 @@ jobs: - name: Get module name uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7 - id: modules_names + id: module_names with: script: | return ${{ steps.filter.outputs.modules_files }}.map(path => path.replace('modules/nf-core/', '').split('/').slice(0,2).filter(x => x !== 'main.nf').join('/')); From 310d9bf1a72a9327de770896df4de5204bef22c5 Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Wed, 20 Nov 2024 20:12:05 -0600 Subject: [PATCH 18/23] ci: Use Set --- .github/workflows/lint.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 2d3ff2a94b1..d2ab48ab63d 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -78,14 +78,14 @@ jobs: id: module_names with: script: | - return ${{ steps.filter.outputs.modules_files }}.map(path => path.replace('modules/nf-core/', '').split('/').slice(0,2).filter(x => x !== 'main.nf').join('/')); + return [...new Set(${{ steps.filter.outputs.modules_files }}.map(path => path.replace('modules/nf-core/', '').split('/').slice(0,2).filter(x => x !== 'main.nf').join('/')))]; - name: Get subworkflow name uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7 id: subworkflow_names with: script: | - return ${{ steps.filter.outputs.subworkflows_files }}.map(path => path.replace('modules/nf-core/', '').split('/').slice(0,2).filter(x => x !== 'main.nf').join('/')); + return [...new Set(${{ steps.filter.outputs.subworkflows_files }}.map(path => path.replace('subworkflows/nf-core/', '').split('/').slice(0,2).filter(x => x !== 'main.nf').join('/')))]; - name: debug run: | From db67782c86b3bec9bdacbc7da81d16fbd3addf48 Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Wed, 20 Nov 2024 20:43:00 -0600 Subject: [PATCH 19/23] ci: Use one at a time --- .github/workflows/lint.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index d2ab48ab63d..b908d9aa2e3 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -102,7 +102,7 @@ jobs: strategy: fail-fast: false matrix: - files: "${{ fromJson(needs.nf-core-changes.outputs.modules_files) }}" + module: "${{ fromJson(needs.nf-core-changes.outputs.modules_files) }}" steps: - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4 @@ -133,8 +133,8 @@ jobs: - name: Install nf-core tools development version run: python -m pip install --upgrade --force-reinstall git+https://github.com/nf-core/tools.git@dev - - name: Lint module ${{needs.nf-core-changes.outputs.modules_files}} - run: nf-core modules lint ${{needs.nf-core-changes.outputs.modules_files}} + - name: Lint module ${{ matrix.module }} + run: nf-core modules lint ${{ matrix.module }} nf-core-lint-subworkflows: runs-on: ubuntu-latest @@ -144,7 +144,7 @@ jobs: strategy: fail-fast: false matrix: - files: "${{ fromJson(needs.nf-core-changes.outputs.subworkflows_files) }}" + subworkflow: "${{ fromJson(needs.nf-core-changes.outputs.subworkflows_files) }}" steps: - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4 @@ -167,8 +167,8 @@ jobs: - name: Install nf-core tools development version run: python -m pip install --upgrade --force-reinstall git+https://github.com/nf-core/tools.git@dev - - name: Lint subworkflow ${{needs.nf-core-changes.outputs.subworkflows_files}} - run: nf-core subworkflows lint ${{needs.nf-core-changes.outputs.subworkflows_files}} + - name: Lint subworkflow ${{ matrix.subworkflow }} + run: nf-core subworkflows lint ${{ matrix.subworkflow }} confirm-pass: runs-on: ubuntu-latest From 08c47e72d8e960341bcd02abebde01bb045c5aa3 Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Wed, 20 Nov 2024 20:55:40 -0600 Subject: [PATCH 20/23] ci(gpu): Update step name --- .github/workflows/gpu-tests.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/gpu-tests.yml b/.github/workflows/gpu-tests.yml index a3152915162..2684d8373ca 100644 --- a/.github/workflows/gpu-tests.yml +++ b/.github/workflows/gpu-tests.yml @@ -43,7 +43,7 @@ jobs: runs-on: ubuntu-latest outputs: # Expose detected tags as 'modules' and 'workflows' output variables - paths: ${{ steps.list.outputs.components }} + paths: ${{ steps.outputs.outputs.components }} modules: ${{ steps.outputs.outputs.modules }} subworkflows: ${{ steps.outputs.outputs.subworkflows}} # Prod for version bumping @@ -74,7 +74,7 @@ jobs: echo subworkflows=$(echo '${{ steps.list.outputs.components }}' | jq '. | map(select(contains("subworkflows"))) | map(gsub("subworkflows/nf-core/"; ""))') >> $GITHUB_OUTPUT - name: debug run: | - echo ${{ steps.filter.outputs.components }} + echo ${{ steps.outputs.outputs.components }} echo ${{ steps.outputs.outputs.modules }} echo ${{ steps.outputs.outputs.subworkflows }} From 49b18f951de522f87751f749306c4d97efb2b27c Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Wed, 20 Nov 2024 21:07:54 -0600 Subject: [PATCH 21/23] ci: Remove clean workspace after run --- .github/actions/nf-test-action/action.yml | 9 --------- 1 file changed, 9 deletions(-) diff --git a/.github/actions/nf-test-action/action.yml b/.github/actions/nf-test-action/action.yml index d3b0bb3e469..1fdfcd83a98 100644 --- a/.github/actions/nf-test-action/action.yml +++ b/.github/actions/nf-test-action/action.yml @@ -98,12 +98,3 @@ runs: shell: bash run: | sudo rm -rf /home/ubuntu/tests/ - - - name: Clean Workspace # Purge the workspace in case it's running on a self-hosted runner - if: always() - shell: bash - run: | - ls -la ./ - rm -rf ./* || true - rm -rf ./.??* || true - ls -la ./ From afa0268bbf4cf6d62a506e87fa82e7b9ce724bba Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Wed, 20 Nov 2024 21:09:22 -0600 Subject: [PATCH 22/23] ci: Why does that break things? --- .github/actions/nf-test-action/action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/actions/nf-test-action/action.yml b/.github/actions/nf-test-action/action.yml index 1fdfcd83a98..8cd79f21680 100644 --- a/.github/actions/nf-test-action/action.yml +++ b/.github/actions/nf-test-action/action.yml @@ -73,8 +73,8 @@ runs: SENTIEON_LICSRVR_IP: ${{ env.SENTIEON_LICSRVR_IP }} SENTIEON_AUTH_MECH: "GitHub Actions - token" TAGS: ${{ inputs.tags && format('--tag {0}', inputs.tags) || '' }} - NFT_WORKDIR: "~" run: | + NFT_WORKDIR=~ \ nf-test test \ --profile=${{ inputs.profile }} \ --tap=test.tap \ From f2217caca54229d5523d8640d7b193a5974e9e6c Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Wed, 20 Nov 2024 21:19:11 -0600 Subject: [PATCH 23/23] Revert "style: Run lsp on fastqc" This reverts commit da64fcefcade0b863c59055e1c0a429d73cebff4. --- modules/nf-core/fastqc/main.nf | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/modules/nf-core/fastqc/main.nf b/modules/nf-core/fastqc/main.nf index 1a59b73e709..d8989f48122 100644 --- a/modules/nf-core/fastqc/main.nf +++ b/modules/nf-core/fastqc/main.nf @@ -1,19 +1,19 @@ process FASTQC { - tag "${meta.id}" + tag "$meta.id" label 'process_medium' conda "${moduleDir}/environment.yml" - container "${workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container - ? 'https://depot.galaxyproject.org/singularity/fastqc:0.12.1--hdfd78af_0' - : 'biocontainers/fastqc:0.12.1--hdfd78af_0'}" + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/fastqc:0.12.1--hdfd78af_0' : + 'biocontainers/fastqc:0.12.1--hdfd78af_0' }" input: tuple val(meta), path(reads) output: tuple val(meta), path("*.html"), emit: html - tuple val(meta), path("*.zip"), emit: zip - path "versions.yml", emit: versions + tuple val(meta), path("*.zip") , emit: zip + path "versions.yml" , emit: versions when: task.ext.when == null || task.ext.when @@ -22,9 +22,9 @@ process FASTQC { def args = task.ext.args ?: '' def prefix = task.ext.prefix ?: "${meta.id}" // Make list of old name and new name pairs to use for renaming in the bash while loop - def old_new_pairs = reads instanceof Path || reads.size() == 1 ? [[reads, "${prefix}.${reads.extension}"]] : reads.withIndex().collect { entry, index -> [entry, "${prefix}_${index + 1}.${entry.extension}"] } - def rename_to = old_new_pairs.join(' ').join(' ') - def renamed_files = old_new_pairs.collect { old_name, new_name -> new_name }.join(' ') + def old_new_pairs = reads instanceof Path || reads.size() == 1 ? [[ reads, "${prefix}.${reads.extension}" ]] : reads.withIndex().collect { entry, index -> [ entry, "${prefix}_${index + 1}.${entry.extension}" ] } + def rename_to = old_new_pairs*.join(' ').join(' ') + def renamed_files = old_new_pairs.collect{ old_name, new_name -> new_name }.join(' ') // The total amount of allocated RAM by FastQC is equal to the number of threads defined (--threads) time the amount of RAM defined (--memory) // https://github.com/s-andrews/FastQC/blob/1faeea0412093224d7f6a07f777fad60a5650795/fastqc#L211-L222 @@ -34,15 +34,15 @@ process FASTQC { def fastqc_memory = memory_in_mb > 10000 ? 10000 : (memory_in_mb < 100 ? 100 : memory_in_mb) """ - printf "%s %s\\n" ${rename_to} | while read old_name new_name; do + printf "%s %s\\n" $rename_to | while read old_name new_name; do [ -f "\${new_name}" ] || ln -s \$old_name \$new_name done fastqc \\ - ${args} \\ - --threads ${task.cpus} \\ - --memory ${fastqc_memory} \\ - ${renamed_files} + $args \\ + --threads $task.cpus \\ + --memory $fastqc_memory \\ + $renamed_files cat <<-END_VERSIONS > versions.yml "${task.process}":