diff --git a/.editorconfig b/.editorconfig index a6981b47..835c83dd 100644 --- a/.editorconfig +++ b/.editorconfig @@ -8,5 +8,5 @@ trim_trailing_whitespace = true indent_size = 4 indent_style = space -[*.{yml,yaml}] +[*.{md,yml,yaml}] indent_size = 2 diff --git a/.github/CONTRIBUTING.md b/.github/CONTRIBUTING.md index 7faf4340..cba1dc95 100644 --- a/.github/CONTRIBUTING.md +++ b/.github/CONTRIBUTING.md @@ -16,7 +16,9 @@ Contributions to the code are even more welcome ;) If you'd like to write some code for nf-core/modules, the standard workflow is as follows: 1. Check that there isn't already an issue about your idea in the [nf-core/modules issues](https://github.com/nf-core/modules/issues) to avoid duplicating work - * If there isn't one already, please create one so that others know you're working on this + +- If there isn't one already, please create one so that others know you're working on this + 2. [Fork](https://help.github.com/en/github/getting-started-with-github/fork-a-repo) the [nf-core/modules repository](https://github.com/nf-core/modules) to your GitHub account 3. When adding a module file, follow the [guidelines](https://github.com/nf-core/modules#adding-a-new-module-file) 4. Ensure that [tests are working locally](https://github.com/nf-core/modules#running-tests-locally) @@ -40,7 +42,6 @@ These tests are run both with the latest available version of `Nextflow` and als For further information/help, please consult the [nf-core/modules README](https://github.com/nf-core/modules) and don't hesitate to get in touch on the nf-core Slack [#modules](https://nfcore.slack.com/channels/modules) channel ([join our Slack here](https://nf-co.re/join/slack)). - ### Images and figures For overview images and other documents we follow the nf-core [style guidelines and examples](https://nf-co.re/developers/design_guidelines). diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index cfe07f88..8fc9ae0d 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -27,6 +27,6 @@ Closes #XXX - [ ] Add a resource `label` - [ ] Use BioConda and BioContainers if possible to fulfil software requirements. - Ensure that the test works with either Docker / Singularity. Conda CI tests can be quite flaky: - - [ ] `PROFILE=docker pytest --tag --symlink --keep-workflow-wd --git-aware` - - [ ] `PROFILE=singularity pytest --tag --symlink --keep-workflow-wd --git-aware` - - [ ] `PROFILE=conda pytest --tag --symlink --keep-workflow-wd --git-aware` + - [ ] `PROFILE=docker pytest --tag --symlink --keep-workflow-wd --git-aware` + - [ ] `PROFILE=singularity pytest --tag --symlink --keep-workflow-wd --git-aware` + - [ ] `PROFILE=conda pytest --tag --symlink --keep-workflow-wd --git-aware` diff --git a/.github/workflows/code-linting.yml b/.github/workflows/code-linting.yml index 145dd5d9..9b066467 100644 --- a/.github/workflows/code-linting.yml +++ b/.github/workflows/code-linting.yml @@ -5,20 +5,21 @@ on: pull_request: branches: [master] - jobs: - Markdown: + Prettier: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - name: Check out repository + uses: actions/checkout@v2 - - uses: actions/setup-node@v2 + - name: Install NodeJS + uses: actions/setup-node@v2 - - name: Install markdownlint - run: npm install -g markdownlint-cli + - name: Install Prettier + run: npm install -g prettier - - name: Run Markdownlint - run: markdownlint ${GITHUB_WORKSPACE} -c ${GITHUB_WORKSPACE}/.markdownlint.yml + - name: Run Prettier --check + run: prettier --check . EditorConfig: runs-on: ubuntu-latest @@ -32,18 +33,3 @@ jobs: - name: Run ECLint check run: editorconfig-checker -exclude README.md $(git ls-files | grep -v test) - - YAML: - runs-on: ubuntu-latest - steps: - - name: Check out repository - uses: actions/checkout@v2 - - - name: Install NodeJS - uses: actions/setup-node@v2 - - - name: Install yaml-lint - run: npm install -g yaml-lint - - - name: Run yaml-lint - run: yamllint $(find ${GITHUB_WORKSPACE} -type f -name "*.yaml" -or -name "*.yml") diff --git a/.gitpod.yml b/.gitpod.yml index 25078360..d24968be 100644 --- a/.gitpod.yml +++ b/.gitpod.yml @@ -1,14 +1,14 @@ image: nfcore/gitpod:latest vscode: - extensions: # based on nf-core.nf-core-extensionpack - - codezombiech.gitignore # Language support for .gitignore files + extensions: # based on nf-core.nf-core-extensionpack + - codezombiech.gitignore # Language support for .gitignore files # - cssho.vscode-svgviewer # SVG viewer - - davidanson.vscode-markdownlint # Markdown/CommonMark linting and style checking for Visual Studio Code - - eamodio.gitlens # Quickly glimpse into whom, why, and when a line or code block was changed - - EditorConfig.EditorConfig # override user/workspace settings with settings found in .editorconfig files - - Gruntfuggly.todo-tree # Display TODO and FIXME in a tree view in the activity bar - - mechatroner.rainbow-csv # Highlight columns in csv files in different colors + - esbenp.prettier-vscode # Markdown/CommonMark linting and style checking for Visual Studio Code + - eamodio.gitlens # Quickly glimpse into whom, why, and when a line or code block was changed + - EditorConfig.EditorConfig # override user/workspace settings with settings found in .editorconfig files + - Gruntfuggly.todo-tree # Display TODO and FIXME in a tree view in the activity bar + - mechatroner.rainbow-csv # Highlight columns in csv files in different colors # - nextflow.nextflow # Nextflow syntax highlighting - - oderwat.indent-rainbow # Highlight indentation level - - streetsidesoftware.code-spell-checker # Spelling checker for source code + - oderwat.indent-rainbow # Highlight indentation level + - streetsidesoftware.code-spell-checker # Spelling checker for source code diff --git a/.markdownlint.yml b/.markdownlint.yml deleted file mode 100644 index 7890d0f2..00000000 --- a/.markdownlint.yml +++ /dev/null @@ -1,11 +0,0 @@ -# Markdownlint configuration file -default: true -line-length: false -no-multiple-blanks: 0 -blanks-around-headers: false -blanks-around-lists: false -header-increment: false -no-duplicate-header: - siblings_only: true -ul-indent: - indent: 4 diff --git a/.prettierignore b/.prettierignore new file mode 100644 index 00000000..a76cd9ac --- /dev/null +++ b/.prettierignore @@ -0,0 +1,16 @@ +includes/Maven_Pro/ + +# gitignore +.nextflow* +work/ +results/ +test_output/ +output/ +.DS_Store +*.code-workspace +tests/data/ +.screenrc +.*.sw? +__pycache__ +*.pyo +*.pyc diff --git a/.prettierrc.yml b/.prettierrc.yml new file mode 100644 index 00000000..c81f9a76 --- /dev/null +++ b/.prettierrc.yml @@ -0,0 +1 @@ +printWidth: 120 diff --git a/.yamllint.yml b/.yamllint.yml deleted file mode 100644 index 6889fa34..00000000 --- a/.yamllint.yml +++ /dev/null @@ -1,5 +0,0 @@ -extends: default - -rules: - document-start: disable - line-length: disable diff --git a/README.md b/README.md index beee42e7..478fe8da 100644 --- a/README.md +++ b/README.md @@ -31,105 +31,105 @@ We have written a helper command in the `nf-core/tools` package that uses the Gi 1. Install the latest version of [`nf-core/tools`](https://github.com/nf-core/tools#installation) (`>=2.0`) 2. List the available modules: - ```console - $ nf-core modules list remote + ```console + $ nf-core modules list remote - ,--./,-. - ___ __ __ __ ___ /,-._.--~\ - |\ | |__ __ / ` / \ |__) |__ } { - | \| | \__, \__/ | \ |___ \`-._,-`-, - `._,._,' + ,--./,-. + ___ __ __ __ ___ /,-._.--~\ + |\ | |__ __ / ` / \ |__) |__ } { + | \| | \__, \__/ | \ |___ \`-._,-`-, + `._,._,' - nf-core/tools version 2.0 + nf-core/tools version 2.0 - INFO Modules available from nf-core/modules (master): pipeline_modules.py:164 + INFO Modules available from nf-core/modules (master): pipeline_modules.py:164 - ┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓ - ┃ Module Name ┃ - ┡━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┩ - │ bandage/image │ - │ bcftools/consensus │ - │ bcftools/filter │ - │ bcftools/isec │ - ..truncated.. - ``` + ┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓ + ┃ Module Name ┃ + ┡━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┩ + │ bandage/image │ + │ bcftools/consensus │ + │ bcftools/filter │ + │ bcftools/isec │ + ..truncated.. + ``` 3. Install the module in your pipeline directory: - ```console - $ nf-core modules install fastqc + ```console + $ nf-core modules install fastqc - ,--./,-. - ___ __ __ __ ___ /,-._.--~\ - |\ | |__ __ / ` / \ |__) |__ } { - | \| | \__, \__/ | \ |___ \`-._,-`-, - `._,._,' + ,--./,-. + ___ __ __ __ ___ /,-._.--~\ + |\ | |__ __ / ` / \ |__) |__ } { + | \| | \__, \__/ | \ |___ \`-._,-`-, + `._,._,' - nf-core/tools version 2.0 + nf-core/tools version 2.0 - INFO Installing fastqc pipeline_modules.py:213 - INFO Downloaded 3 files to ./modules/nf-core/modules/fastqc pipeline_modules.py:236 - ``` + INFO Installing fastqc pipeline_modules.py:213 + INFO Downloaded 3 files to ./modules/nf-core/modules/fastqc pipeline_modules.py:236 + ``` 4. Import the module in your Nextflow script: - ```nextflow - #!/usr/bin/env nextflow + ```nextflow + #!/usr/bin/env nextflow - nextflow.enable.dsl = 2 + nextflow.enable.dsl = 2 - include { FASTQC } from './modules/nf-core/modules/fastqc/main' - ``` + include { FASTQC } from './modules/nf-core/modules/fastqc/main' + ``` 5. Remove the module from the pipeline repository if required: - ```console - $ nf-core modules remove fastqc + ```console + $ nf-core modules remove fastqc - ,--./,-. - ___ __ __ __ ___ /,-._.--~\ - |\ | |__ __ / ` / \ |__) |__ } { - | \| | \__, \__/ | \ |___ \`-._,-`-, - `._,._,' + ,--./,-. + ___ __ __ __ ___ /,-._.--~\ + |\ | |__ __ / ` / \ |__) |__ } { + | \| | \__, \__/ | \ |___ \`-._,-`-, + `._,._,' - nf-core/tools version 2.0 + nf-core/tools version 2.0 - INFO Removing fastqc pipeline_modules.py:271 - INFO Successfully removed fastqc pipeline_modules.py:285 - ``` + INFO Removing fastqc pipeline_modules.py:271 + INFO Successfully removed fastqc pipeline_modules.py:285 + ``` 6. Check that a locally installed nf-core module is up-to-date compared to the one hosted in this repo: - ```console - $ nf-core modules lint fastqc + ```console + $ nf-core modules lint fastqc - ,--./,-. - ___ __ __ __ ___ /,-._.--~\ - |\ | |__ __ / ` / \ |__) |__ } { - | \| | \__, \__/ | \ |___ \`-._,-`-, - `._,._,' + ,--./,-. + ___ __ __ __ ___ /,-._.--~\ + |\ | |__ __ / ` / \ |__) |__ } { + | \| | \__, \__/ | \ |___ \`-._,-`-, + `._,._,' - nf-core/tools version 2.0 + nf-core/tools version 2.0 - INFO Linting pipeline: . lint.py:104 - INFO Linting module: fastqc lint.py:106 + INFO Linting pipeline: . lint.py:104 + INFO Linting module: fastqc lint.py:106 - ╭─────────────────────────────────────────────────────────────────────────────────╮ - │ [!] 1 Test Warning │ - ╰─────────────────────────────────────────────────────────────────────────────────╯ - ╭──────────────┬───────────────────────────────┬──────────────────────────────────╮ - │ Module name │ Test message │ File path │ - ├──────────────┼───────────────────────────────┼──────────────────────────────────┤ - │ fastqc │ Local copy of module outdated │ modules/nf-core/modules/fastqc/ │ - ╰──────────────┴────────────────────────────── ┴──────────────────────────────────╯ - ╭──────────────────────╮ - │ LINT RESULTS SUMMARY │ - ├──────────────────────┤ - │ [✔] 15 Tests Passed │ - │ [!] 1 Test Warning │ - │ [✗] 0 Test Failed │ - ╰──────────────────────╯ - ``` + ╭─────────────────────────────────────────────────────────────────────────────────╮ + │ [!] 1 Test Warning │ + ╰─────────────────────────────────────────────────────────────────────────────────╯ + ╭──────────────┬───────────────────────────────┬──────────────────────────────────╮ + │ Module name │ Test message │ File path │ + ├──────────────┼───────────────────────────────┼──────────────────────────────────┤ + │ fastqc │ Local copy of module outdated │ modules/nf-core/modules/fastqc/ │ + ╰──────────────┴────────────────────────────── ┴──────────────────────────────────╯ + ╭──────────────────────╮ + │ LINT RESULTS SUMMARY │ + ├──────────────────────┤ + │ [✔] 15 Tests Passed │ + │ [!] 1 Test Warning │ + │ [✗] 0 Test Failed │ + ╰──────────────────────╯ + ``` ## Adding new modules diff --git a/modules/abricate/run/meta.yml b/modules/abricate/run/meta.yml index 2464d03e..1365bcd7 100644 --- a/modules/abricate/run/meta.yml +++ b/modules/abricate/run/meta.yml @@ -11,7 +11,7 @@ tools: documentation: https://github.com/tseemann/abricate tool_dev_url: https://github.com/tseemann/abricate doi: "" - licence: ['GPL v2', 'GPL v2'] + licence: ["GPL v2", "GPL v2"] input: - meta: diff --git a/modules/abricate/summary/meta.yml b/modules/abricate/summary/meta.yml index b02ba930..c6653b80 100644 --- a/modules/abricate/summary/meta.yml +++ b/modules/abricate/summary/meta.yml @@ -11,7 +11,7 @@ tools: documentation: https://github.com/tseemann/abricate tool_dev_url: https://github.com/tseemann/abricate doi: "" - licence: ['GPL v2', 'GPL v2'] + licence: ["GPL v2", "GPL v2"] input: - meta: diff --git a/modules/adapterremoval/meta.yml b/modules/adapterremoval/meta.yml index e395fe4a..5faad043 100644 --- a/modules/adapterremoval/meta.yml +++ b/modules/adapterremoval/meta.yml @@ -26,8 +26,7 @@ input: pattern: "*.{fq,fastq,fq.gz,fastq.gz}" - adapterlist: type: file - description: - Optional text file containing list of adapters to look for for removal + description: Optional text file containing list of adapters to look for for removal with one adapter per line. Otherwise will look for default adapters (see AdapterRemoval man page), or can be modified to remove user-specified adapters via ext.args. diff --git a/modules/amrfinderplus/run/meta.yml b/modules/amrfinderplus/run/meta.yml index b0f3b8fa..813adf3e 100644 --- a/modules/amrfinderplus/run/meta.yml +++ b/modules/amrfinderplus/run/meta.yml @@ -11,7 +11,7 @@ tools: documentation: https://github.com/ncbi/amr/wiki tool_dev_url: https://github.com/ncbi/amr doi: "10.1038/s41598-021-91456-0" - licence: ['Public Domain'] + licence: ["Public Domain"] input: - meta: diff --git a/modules/amrfinderplus/update/meta.yml b/modules/amrfinderplus/update/meta.yml index 84fee3df..0e20a92f 100644 --- a/modules/amrfinderplus/update/meta.yml +++ b/modules/amrfinderplus/update/meta.yml @@ -11,7 +11,7 @@ tools: documentation: https://github.com/ncbi/amr/wiki tool_dev_url: https://github.com/ncbi/amr doi: "10.1038/s41598-021-91456-0" - licence: ['Public Domain'] + licence: ["Public Domain"] input: - input_not_required: diff --git a/modules/ascat/meta.yml b/modules/ascat/meta.yml index b44862a1..00d86069 100644 --- a/modules/ascat/meta.yml +++ b/modules/ascat/meta.yml @@ -9,7 +9,7 @@ tools: documentation: None tool_dev_url: https://github.com/Crick-CancerGenomics/ascat doi: "10.1093/bioinformatics/btaa538" - licence: ['GPL v3'] + licence: ["GPL v3"] input: - args: diff --git a/modules/bcftools/annotate/meta.yml b/modules/bcftools/annotate/meta.yml index 3ed124d5..afe447c1 100644 --- a/modules/bcftools/annotate/meta.yml +++ b/modules/bcftools/annotate/meta.yml @@ -12,7 +12,7 @@ tools: homepage: http://samtools.github.io/bcftools/bcftools.html documentation: https://samtools.github.io/bcftools/bcftools.html#annotate doi: 10.1093/bioinformatics/btp352 - licence: ['MIT'] + licence: ["MIT"] input: - meta: diff --git a/modules/biscuit/pileup/meta.yml b/modules/biscuit/pileup/meta.yml index 399e3c2f..87c3891a 100644 --- a/modules/biscuit/pileup/meta.yml +++ b/modules/biscuit/pileup/meta.yml @@ -27,9 +27,9 @@ input: - normal_bams: type: file(s) description: | - BAM files to be analyzed. If no tumor_bam file is provided, any number of "normal" BAMs may be provided - ("normal" here is just a semantic issue, these BAMs could be from tumor or any other kind of tissue). If a - tumor BAM file is provided, exactly one normal (germline) BAM must be provided. + BAM files to be analyzed. If no tumor_bam file is provided, any number of "normal" BAMs may be provided + ("normal" here is just a semantic issue, these BAMs could be from tumor or any other kind of tissue). If a + tumor BAM file is provided, exactly one normal (germline) BAM must be provided. pattern: "*.{bam}" - normal_bais: type: file(s) @@ -38,9 +38,9 @@ input: - tumor_bam: type: file(s) description: | - Optional. If a tumor BAM file is provided, pileup will run in "somatic" mode and will annotate variants with - their somatic state (present in tumor only, present in normal only, present in both, etc). Note that if a - tumor BAM file is provided, exactly one normal BAM must be provided. + Optional. If a tumor BAM file is provided, pileup will run in "somatic" mode and will annotate variants with + their somatic state (present in tumor only, present in normal only, present in both, etc). Note that if a + tumor BAM file is provided, exactly one normal BAM must be provided. pattern: "*.{bam}" - tumor_bai: type: file(s) diff --git a/modules/cellranger/README.md b/modules/cellranger/README.md index d31735cb..312fd218 100644 --- a/modules/cellranger/README.md +++ b/modules/cellranger/README.md @@ -2,23 +2,22 @@ Cell Ranger is a commercial tool from 10X Genomics. The container provided for the cellranger nf-core module is not provided nor supported by 10x Genomics. Updating the Cell Ranger versions in the container and pushing the update to Dockerhub needs to be done manually. -1. Navigate to the appropriate download page. - - [Cell Ranger](https://support.10xgenomics.com/single-cell-gene-expression/software/downloads/latest): download the tar ball of the desired Cell Ranger version with `curl` or `wget`. Place this file in the same folder where the Dockerfile lies. +1. Navigate to the appropriate download page. - [Cell Ranger](https://support.10xgenomics.com/single-cell-gene-expression/software/downloads/latest): download the tar ball of the desired Cell Ranger version with `curl` or `wget`. Place this file in the same folder where the Dockerfile lies. 2. Edit the Dockerfile. Update the Cell Ranger versions in this line: - ```bash - ENV CELLRANGER_VER= - ``` + ```bash + ENV CELLRANGER_VER= + ``` 3. Create and test the container: - ```bash - docker build . -t nfcore/cellranger: - ``` + ```bash + docker build . -t nfcore/cellranger: + ``` 4. Access rights are needed to push the container to the Dockerhub nfcore organization, please ask a core team member to do so. - ```bash - docker push nfcore/cellranger: - ``` + ```bash + docker push nfcore/cellranger: + ``` diff --git a/modules/cellranger/mkfastq/README.md b/modules/cellranger/mkfastq/README.md index 07c3919b..e281ded3 100644 --- a/modules/cellranger/mkfastq/README.md +++ b/modules/cellranger/mkfastq/README.md @@ -2,25 +2,23 @@ Bcl2fastq2 and Cell Ranger are commercial tools from Illumina and 10X Genomics, respectively. The container provided for the cellranger nf-core module is not provided nor supported by either Illumina or 10x Genomics. Updating the bcl2fastq2 or Cell Ranger versions in the container and pushing the update to Dockerhub needs to be done manually. -1. Navigate to the appropriate download pages. - - [bcl2fastq2](https://emea.support.illumina.com/sequencing/sequencing_software/bcl2fastq-conversion-software.html): download the linux rpm installer of the desired bcl2fastq2 version with `curl` or `wget`. Place this file in the same folder where the Dockerfile lies. - - [Cell Ranger](https://support.10xgenomics.com/single-cell-gene-expression/software/downloads/latest): download the tar ball of the desired Cell Ranger version with `curl` or `wget`. Place this file in the same folder where the Dockerfile lies. +1. Navigate to the appropriate download pages. - [bcl2fastq2](https://emea.support.illumina.com/sequencing/sequencing_software/bcl2fastq-conversion-software.html): download the linux rpm installer of the desired bcl2fastq2 version with `curl` or `wget`. Place this file in the same folder where the Dockerfile lies. - [Cell Ranger](https://support.10xgenomics.com/single-cell-gene-expression/software/downloads/latest): download the tar ball of the desired Cell Ranger version with `curl` or `wget`. Place this file in the same folder where the Dockerfile lies. 2. Edit the Dockerfile. Update the bcl2fastq2 and Cell Ranger versions in this line: - ```bash - ENV BCL2FASTQ2_VER= \ - CELLRANGER_VER= - ``` + ```bash + ENV BCL2FASTQ2_VER= \ + CELLRANGER_VER= + ``` 3. Create and test the container: - ```bash - docker build . -t nfcore/cellrangermkfastq: - ``` + ```bash + docker build . -t nfcore/cellrangermkfastq: + ``` 4. Access rights are needed to push the container to the Dockerhub nfcore organization, please ask a core team member to do so. - ```bash - docker push nfcore/cellrangermkfastq: - ``` + ```bash + docker push nfcore/cellrangermkfastq: + ``` diff --git a/modules/centrifuge/main.nf b/modules/centrifuge/main.nf new file mode 100644 index 00000000..7eb566da --- /dev/null +++ b/modules/centrifuge/main.nf @@ -0,0 +1,63 @@ +process CENTRIFUGE { + tag "$meta.id" + label 'process_high' + + conda (params.enable_conda ? "bioconda::centrifuge=1.0.4_beta" : null) + container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? + 'https://depot.galaxyproject.org/singularity/centrifuge:1.0.4_beta--h9a82719_6' : + 'quay.io/biocontainers/centrifuge:1.0.4_beta--h9a82719_6' }" + + input: + tuple val(meta), path(reads) + path db + val save_unaligned + val save_aligned + val sam_format + + output: + tuple val(meta), path('*report.txt') , emit: report + tuple val(meta), path('*results.txt') , emit: results + tuple val(meta), path('*kreport.txt') , emit: kreport + tuple val(meta), path('*.sam') , optional: true, emit: sam + tuple val(meta), path('*.mapped.fastq{,.1,.2}.gz') , optional: true, emit: fastq_mapped + tuple val(meta), path('*.unmapped.fastq{,.1,.2}.gz') , optional: true, emit: fastq_unmapped + path "versions.yml" , emit: versions + + when: + task.ext.when == null || task.ext.when + + script: + def args = task.ext.args ?: '' + def prefix = task.ext.prefix ?: "${meta.id}" + def paired = meta.single_end ? "-U ${reads}" : "-1 ${reads[0]} -2 ${reads[1]}" + def db_name = db.toString().replace(".tar.gz","") + def unaligned = '' + def aligned = '' + if (meta.single_end) { + unaligned = save_unaligned ? "--un-gz ${prefix}.unmapped.fastq.gz" : '' + aligned = save_aligned ? "--al-gz ${prefix}.mapped.fastq.gz" : '' + } else { + unaligned = save_unaligned ? "--un-conc-gz ${prefix}.unmapped.fastq.gz" : '' + aligned = save_aligned ? "--al-conc-gz ${prefix}.mapped.fastq.gz" : '' + } + def sam_output = sam_format ? "--out-fmt 'sam'" : '' + """ + tar -xf $db + centrifuge \\ + -x $db_name \\ + -p $task.cpus \\ + $paired \\ + --report-file ${prefix}.report.txt \\ + -S ${prefix}.results.txt \\ + $unaligned \\ + $aligned \\ + $sam_output \\ + $args + centrifuge-kreport -x $db_name ${prefix}.results.txt > ${prefix}.kreport.txt + + cat <<-END_VERSIONS > versions.yml + "${task.process}": + centrifuge: \$( centrifuge --version | sed -n 1p | sed 's/^.*centrifuge-class version //') + END_VERSIONS + """ +} diff --git a/modules/centrifuge/meta.yml b/modules/centrifuge/meta.yml new file mode 100644 index 00000000..3adf0e23 --- /dev/null +++ b/modules/centrifuge/meta.yml @@ -0,0 +1,73 @@ +name: centrifuge +description: Classifies metagenomic sequence data +keywords: + - classify + - metagenomics + - fastq + - db +tools: + - centrifuge: + description: Centrifuge is a classifier for metagenomic sequences. + homepage: https://ccb.jhu.edu/software/centrifuge/ + documentation: https://ccb.jhu.edu/software/centrifuge/manual.shtml + doi: 10.1101/gr.210641.116 + licence: ["GPL v3"] +input: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - reads: + type: file + description: | + List of input FastQ files of size 1 and 2 for single-end and paired-end data, + respectively. + - db: + type: directory + description: Centrifuge database in .tar.gz format + pattern: "*.tar.gz" + - save_unaligned: + type: value + description: If true unmapped fastq files are saved + - save_aligned: + type: value + description: If true mapped fastq files are saved +output: + - meta: + type: map + description: | + Groovy Map containing sample information + e.g. [ id:'test', single_end:false ] + - report: + type: file + description: | + File containing a classification summary + pattern: "*.{report.txt}" + - results: + type: file + description: | + File containing classification results + pattern: "*.{results.txt}" + - kreport: + type: file + description: | + File containing kraken-style report from centrifuge + out files. + pattern: "*.{kreport.txt}" + - fastq_unmapped: + type: file + description: Unmapped fastq files + pattern: "*.unmapped.fastq.gz" + - fastq_mapped: + type: file + description: Mapped fastq files + pattern: "*.mapped.fastq.gz" + - versions: + type: file + description: File containing software versions + pattern: "versions.yml" +authors: + - "@sofstam" + - "@jfy133" + - "@sateeshperi" diff --git a/modules/cnvpytor/callcnvs/meta.yml b/modules/cnvpytor/callcnvs/meta.yml index c153b949..edfc462a 100644 --- a/modules/cnvpytor/callcnvs/meta.yml +++ b/modules/cnvpytor/callcnvs/meta.yml @@ -8,7 +8,7 @@ tools: documentation: https://github.com/abyzovlab/CNVpytor tool_dev_url: https://github.com/abyzovlab/CNVpytor doi: "10.1101/2021.01.27.428472v1" - licence: ['MIT'] + licence: ["MIT"] input: - meta: type: map @@ -35,6 +35,5 @@ output: description: File containing software versions pattern: "versions.yml" - authors: - "@sima-r" diff --git a/modules/cnvpytor/histogram/meta.yml b/modules/cnvpytor/histogram/meta.yml index 8484ddd4..fcad2221 100644 --- a/modules/cnvpytor/histogram/meta.yml +++ b/modules/cnvpytor/histogram/meta.yml @@ -10,7 +10,7 @@ tools: documentation: https://github.com/abyzovlab/CNVpytor tool_dev_url: https://github.com/abyzovlab/CNVpytor doi: "10.1101/2021.01.27.428472v1" - licence: ['MIT'] + licence: ["MIT"] input: - meta: diff --git a/modules/cnvpytor/importreaddepth/meta.yml b/modules/cnvpytor/importreaddepth/meta.yml index 908c3a74..1cf3c0d0 100644 --- a/modules/cnvpytor/importreaddepth/meta.yml +++ b/modules/cnvpytor/importreaddepth/meta.yml @@ -10,7 +10,7 @@ tools: documentation: https://github.com/abyzovlab/CNVpytor tool_dev_url: https://github.com/abyzovlab/CNVpytor doi: "10.1101/2021.01.27.428472v1" - licence: ['MIT'] + licence: ["MIT"] input: - meta: @@ -35,7 +35,6 @@ input: description: Index of reference fasta file pattern: "*.fai" - output: - meta: type: map diff --git a/modules/cnvpytor/partition/meta.yml b/modules/cnvpytor/partition/meta.yml index 3f0a3e21..a72cea4c 100644 --- a/modules/cnvpytor/partition/meta.yml +++ b/modules/cnvpytor/partition/meta.yml @@ -10,7 +10,7 @@ tools: documentation: https://github.com/abyzovlab/CNVpytor tool_dev_url: https://github.com/abyzovlab/CNVpytor doi: "10.1101/2021.01.27.428472v1" - licence: ['MIT'] + licence: ["MIT"] input: - meta: diff --git a/modules/controlfreec/meta.yml b/modules/controlfreec/meta.yml index 3e218037..b2a6772b 100644 --- a/modules/controlfreec/meta.yml +++ b/modules/controlfreec/meta.yml @@ -13,7 +13,7 @@ tools: documentation: http://boevalab.inf.ethz.ch/FREEC/tutorial.html tool_dev_url: https://github.com/BoevaLab/FREEC/ doi: "10.1093/bioinformatics/btq635" - licence: ['GPL >=2'] + licence: ["GPL >=2"] input: - args: @@ -131,7 +131,6 @@ input: description: Sorted bed file containing capture regions (optional) pattern: "*.bed" - output: - meta: type: map diff --git a/modules/csvtk/split/meta.yml b/modules/csvtk/split/meta.yml index 334cc6ac..64373633 100644 --- a/modules/csvtk/split/meta.yml +++ b/modules/csvtk/split/meta.yml @@ -6,8 +6,7 @@ keywords: - tsv tools: - csvtk: - description: - CSVTK is a cross-platform, efficient and practical CSV/TSV toolkit + description: CSVTK is a cross-platform, efficient and practical CSV/TSV toolkit that allows rapid data investigation and manipulation. homepage: https://bioinf.shenwei.me/csvtk/ documentation: https://bioinf.shenwei.me/csvtk/ diff --git a/modules/deeparg/downloaddata/main.nf b/modules/deeparg/downloaddata/main.nf index 78208d21..4e007f14 100644 --- a/modules/deeparg/downloaddata/main.nf +++ b/modules/deeparg/downloaddata/main.nf @@ -8,10 +8,10 @@ process DEEPARG_DOWNLOADDATA { 'https://depot.galaxyproject.org/singularity/deeparg:1.0.2--pyhdfd78af_1' : 'quay.io/biocontainers/deeparg:1.0.2--pyhdfd78af_1' }" /* - We have to force singularity to run with --fakeroot to allow reading of a problematic file with borked read-write permissions in an upstream dependency (theanos). - This flag may not be available on all systems and may be considered a security problem. so please document and /or warn for this in your pipeline! + We have to force singularity to run with -B to allow reading of a problematic file with borked read-write permissions in an upstream dependency (theanos). + Original report: https://github.com/nf-core/funcscan/issues/23 */ - containerOptions { "${workflow.containerEngine}" == 'singularity' ? '--fakeroot' : '' } + containerOptions { "${workflow.containerEngine}" == 'singularity' ? '-B $(which bash):/usr/local/lib/python2.7/site-packages/Theano-0.8.2-py2.7.egg-info/PKG-INFO' : '' } input: diff --git a/modules/deeparg/downloaddata/meta.yml b/modules/deeparg/downloaddata/meta.yml index 352999e2..b6b1881e 100644 --- a/modules/deeparg/downloaddata/meta.yml +++ b/modules/deeparg/downloaddata/meta.yml @@ -17,7 +17,7 @@ tools: licence: ["MIT"] input: - - none: There is no input. This module downloads a pre-built database for use with deepARG. + - none: No input required for download module. output: - versions: diff --git a/modules/deeparg/predict/main.nf b/modules/deeparg/predict/main.nf index 05cee2f8..7bb4f935 100644 --- a/modules/deeparg/predict/main.nf +++ b/modules/deeparg/predict/main.nf @@ -6,13 +6,13 @@ process DEEPARG_PREDICT { conda (params.enable_conda ? "bioconda::deeparg=1.0.2" : null) container "${ workflow.containerEngine == 'singularity' && !task.ext.singularity_pull_docker_container ? - 'https://depot.galaxyproject.org/singularity//deeparg:1.0.2--pyhdfd78af_1' : + 'https://depot.galaxyproject.org/singularity/deeparg:1.0.2--pyhdfd78af_1' : 'quay.io/biocontainers/deeparg:1.0.2--pyhdfd78af_1' }" /* - We have to force singularity to run with --fakeroot to allow reading of a problematic file with borked read-write permissions in an upstream dependency (theanos). - This flag may not be available on all systems and may be considered a security problem. so please document and /or warn for this in your pipeline! + We have to force singularity to run with -B to allow reading of a problematic file with borked read-write permissions in an upstream dependency (theanos). + Original report: https://github.com/nf-core/funcscan/issues/23 */ - containerOptions { "${workflow.containerEngine}" == 'singularity' ? '--fakeroot' : '' } + containerOptions { "${workflow.containerEngine}" == 'singularity' ? '-B $(which bash):/usr/local/lib/python2.7/site-packages/Theano-0.8.2-py2.7.egg-info/PKG-INFO' : '' } input: tuple val(meta), path(fasta), val(model) diff --git a/modules/deeptools/bamcoverage/meta.yml b/modules/deeptools/bamcoverage/meta.yml index d0590b2a..fb92168f 100644 --- a/modules/deeptools/bamcoverage/meta.yml +++ b/modules/deeptools/bamcoverage/meta.yml @@ -9,7 +9,7 @@ tools: documentation: https://deeptools.readthedocs.io/en/develop/content/tools/bamCoverage.html tool_dev_url: https://github.com/deeptools/deepTools/ doi: "https://doi.org/10.1093/nar/gkw257" - licence: ['GPL v3'] + licence: ["GPL v3"] input: - meta: diff --git a/modules/faqcs/meta.yml b/modules/faqcs/meta.yml index 1161a13d..df3c2308 100644 --- a/modules/faqcs/meta.yml +++ b/modules/faqcs/meta.yml @@ -13,7 +13,7 @@ tools: documentation: https://github.com/LANL-Bioinformatics/FaQCs tool_dev_url: https://github.com/LANL-Bioinformatics/FaQCs doi: "https://doi.org/10.1186/s12859-014-0366-2" - licence: ['GPLv3 License'] + licence: ["GPLv3 License"] ## TODO nf-core: Add a description of all of the variables used as input input: diff --git a/modules/gatk4/combinegvcfs/meta.yml b/modules/gatk4/combinegvcfs/meta.yml index 2e0198dd..b891de90 100644 --- a/modules/gatk4/combinegvcfs/meta.yml +++ b/modules/gatk4/combinegvcfs/meta.yml @@ -8,14 +8,15 @@ keywords: - Short_Variant_Discovery tools: - gatk4: - description: Genome Analysis Toolkit (GATK4). Developed in the Data Sciences Platform at the Broad Institute, the toolkit offers a wide variety of tools + description: + Genome Analysis Toolkit (GATK4). Developed in the Data Sciences Platform at the Broad Institute, the toolkit offers a wide variety of tools with a primary focus on variant discovery and genotyping. Its powerful processing engine and high-performance computing features make it capable of taking on projects of any size. homepage: https://gatk.broadinstitute.org/hc/en-us documentation: https://gatk.broadinstitute.org/hc/en-us/articles/360037593911-CombineGVCFs tool_dev_url: https://github.com/broadinstitute/gatk doi: 10.1158/1538-7445.AM2017-3590 - licence: ['Apache-2.0'] + licence: ["Apache-2.0"] input: - fasta: diff --git a/modules/gatk4/fastqtosam/meta.yml b/modules/gatk4/fastqtosam/meta.yml index 0b173274..59e305b8 100644 --- a/modules/gatk4/fastqtosam/meta.yml +++ b/modules/gatk4/fastqtosam/meta.yml @@ -24,8 +24,7 @@ input: e.g. [ id:'test', single_end:false ] - reads: type: file - description: - List of input FastQ files of size 1 and 2 for single-end and paired-end data, + description: List of input FastQ files of size 1 and 2 for single-end and paired-end data, respectively. pattern: "*.fastq.gz" diff --git a/modules/gatk4/gatherpileupsummaries/meta.yml b/modules/gatk4/gatherpileupsummaries/meta.yml index 7885a930..2dc92d55 100644 --- a/modules/gatk4/gatherpileupsummaries/meta.yml +++ b/modules/gatk4/gatherpileupsummaries/meta.yml @@ -9,7 +9,7 @@ tools: documentation: https://gatk.broadinstitute.org/hc/en-us tool_dev_url: https://github.com/broadinstitute/gatk doi: "10.1158/1538-7445.AM2017-3590" - licence: ['BSD-3-clause'] + licence: ["BSD-3-clause"] input: - meta: diff --git a/modules/gatk4/getpileupsummaries/meta.yml b/modules/gatk4/getpileupsummaries/meta.yml index a70cf1e5..3a940dea 100644 --- a/modules/gatk4/getpileupsummaries/meta.yml +++ b/modules/gatk4/getpileupsummaries/meta.yml @@ -56,7 +56,6 @@ input: description: Index file for the germline resource. pattern: "*.vcf.gz.tbi" - output: - pileup: type: file diff --git a/modules/gatk4/variantrecalibrator/meta.yml b/modules/gatk4/variantrecalibrator/meta.yml index 92416a58..afe33d7a 100644 --- a/modules/gatk4/variantrecalibrator/meta.yml +++ b/modules/gatk4/variantrecalibrator/meta.yml @@ -52,11 +52,11 @@ input: - resvcfs: type: list description: resource files to be used as truth, training and known sites resources, this imports the files into the module, file names are specified again in the resource_labels to be called via the command. - pattern: '*/hapmap_3.3.hg38_chr21.vcf.gz' + pattern: "*/hapmap_3.3.hg38_chr21.vcf.gz" - restbis: type: list description: tbis for the corresponding vcfs files to be used as truth, training and known resources. - pattern: '*/hapmap_3.3.hg38_chr21.vcf.gz.tbi' + pattern: "*/hapmap_3.3.hg38_chr21.vcf.gz.tbi" - reslabels: type: list description: labels for the resource files to be used as truth, training and known sites resources, label should include an identifier,which kind of resource(s) it is, prior value and name of the file. diff --git a/modules/hamronization/deeparg/meta.yml b/modules/hamronization/deeparg/meta.yml index 0747700e..dc076d06 100644 --- a/modules/hamronization/deeparg/meta.yml +++ b/modules/hamronization/deeparg/meta.yml @@ -12,7 +12,7 @@ tools: documentation: https://github.com/pha4ge/hAMRonization/blob/master/README.md tool_dev_url: https://github.com/pha4ge/hAMRonization doi: "" - licence: ['GNU Lesser General Public v3 (LGPL v3)'] + licence: ["GNU Lesser General Public v3 (LGPL v3)"] input: - meta: diff --git a/modules/hamronization/summarize/meta.yml b/modules/hamronization/summarize/meta.yml index 7665c2c5..dabcd092 100644 --- a/modules/hamronization/summarize/meta.yml +++ b/modules/hamronization/summarize/meta.yml @@ -11,7 +11,7 @@ tools: documentation: https://github.com/pha4ge/hAMRonization/blob/master/README.md tool_dev_url: https://github.com/pha4ge/hAMRonization doi: "" - licence: ['GNU Lesser General Public v3 (LGPL v3)'] + licence: ["GNU Lesser General Public v3 (LGPL v3)"] input: - reports: diff --git a/modules/hmmer/hmmsearch/meta.yml b/modules/hmmer/hmmsearch/meta.yml index b315d668..3f4459ba 100644 --- a/modules/hmmer/hmmsearch/meta.yml +++ b/modules/hmmer/hmmsearch/meta.yml @@ -12,7 +12,7 @@ tools: documentation: http://hmmer.org/documentation.html tool_dev_url: https://github.com/EddyRivasLab/hmmer doi: "10.1371/journal.pcbi.1002195" - licence: ['BSD'] + licence: ["BSD"] input: - meta: diff --git a/modules/hpsuissero/meta.yml b/modules/hpsuissero/meta.yml index 2f48c6c3..55b5de39 100644 --- a/modules/hpsuissero/meta.yml +++ b/modules/hpsuissero/meta.yml @@ -11,7 +11,7 @@ tools: documentation: https://github.com/jimmyliu1326/HpsuisSero tool_dev_url: https://github.com/jimmyliu1326/HpsuisSero doi: "" - licence: ['MIT'] + licence: ["MIT"] input: - meta: diff --git a/modules/ichorcna/createpon/meta.yml b/modules/ichorcna/createpon/meta.yml index ce1eca0a..77b99915 100644 --- a/modules/ichorcna/createpon/meta.yml +++ b/modules/ichorcna/createpon/meta.yml @@ -14,7 +14,7 @@ tools: documentation: https://github.com/broadinstitute/ichorCNA/wiki tool_dev_url: https://github.com/broadinstitute/ichorCNA doi: "10.1038/s41467-017-00965-y" - licence: ['GPL v3'] + licence: ["GPL v3"] input: - wigs: diff --git a/modules/ichorcna/run/meta.yml b/modules/ichorcna/run/meta.yml index f0febddf..9b487997 100644 --- a/modules/ichorcna/run/meta.yml +++ b/modules/ichorcna/run/meta.yml @@ -13,7 +13,7 @@ tools: documentation: https://github.com/broadinstitute/ichorCNA/wiki tool_dev_url: https://github.com/broadinstitute/ichorCNA doi: "10.1038/s41467-017-00965-y" - licence: ['GPL v3'] + licence: ["GPL v3"] input: - meta: diff --git a/modules/legsta/meta.yml b/modules/legsta/meta.yml index 24013c67..e9ca3b43 100644 --- a/modules/legsta/meta.yml +++ b/modules/legsta/meta.yml @@ -10,7 +10,7 @@ tools: documentation: https://github.com/tseemann/legsta tool_dev_url: https://github.com/tseemann/legsta doi: "" - licence: ['GPL v3'] + licence: ["GPL v3"] input: - meta: diff --git a/modules/macs2/callpeak/meta.yml b/modules/macs2/callpeak/meta.yml index 974ea33a..982bc5b2 100644 --- a/modules/macs2/callpeak/meta.yml +++ b/modules/macs2/callpeak/meta.yml @@ -28,8 +28,7 @@ input: description: The control file - macs2_gsize: type: string - description: - Effective genome size. It can be 1.0e+9 or 1000000000, or shortcuts:'hs' for human (2.7e9), + description: Effective genome size. It can be 1.0e+9 or 1000000000, or shortcuts:'hs' for human (2.7e9), 'mm' for mouse (1.87e9), 'ce' for C. elegans (9e7) and 'dm' for fruitfly (1.2e8) output: diff --git a/modules/mafft/meta.yml b/modules/mafft/meta.yml index 10c7f0c2..66bb10b9 100644 --- a/modules/mafft/meta.yml +++ b/modules/mafft/meta.yml @@ -10,7 +10,7 @@ tools: documentation: https://mafft.cbrc.jp/alignment/software/manual/manual.html tool_dev_url: https://mafft.cbrc.jp/alignment/software/source.html doi: "10.1093/nar/gkf436" - licence: ['BSD'] + licence: ["BSD"] input: - meta: diff --git a/modules/manta/germline/main.nf b/modules/manta/germline/main.nf index 5ddba51b..ef6bd4a3 100644 --- a/modules/manta/germline/main.nf +++ b/modules/manta/germline/main.nf @@ -8,10 +8,9 @@ process MANTA_GERMLINE { 'quay.io/biocontainers/manta:1.6.0--h9ee0642_1' }" input: - tuple val(meta), path(input), path(index) + tuple val(meta), path(input), path(index), path(target_bed), path(target_bed_tbi) path fasta path fasta_fai - tuple path(target_bed), path(target_bed_tbi) output: diff --git a/modules/manta/germline/meta.yml b/modules/manta/germline/meta.yml index d6297ead..b719f075 100644 --- a/modules/manta/germline/meta.yml +++ b/modules/manta/germline/meta.yml @@ -31,14 +31,6 @@ input: type: file description: BAM/CRAM/SAM index file. For joint calling use a list of files. pattern: "*.{bai,crai,sai}" - - fasta: - type: file - description: Genome reference FASTA file - pattern: "*.{fa,fasta}" - - fasta_fai: - type: file - description: Genome reference FASTA index file - pattern: "*.{fa.fai,fasta.fai}" - target_bed: type: file description: BED file containing target regions for variant calling @@ -47,6 +39,14 @@ input: type: file description: Index for BED file containing target regions for variant calling pattern: "*.{bed.tbi}" + - fasta: + type: file + description: Genome reference FASTA file + pattern: "*.{fa,fasta}" + - fasta_fai: + type: file + description: Genome reference FASTA index file + pattern: "*.{fa.fai,fasta.fai}" output: - meta: diff --git a/modules/manta/somatic/main.nf b/modules/manta/somatic/main.nf index 886a8fb9..6313c38b 100644 --- a/modules/manta/somatic/main.nf +++ b/modules/manta/somatic/main.nf @@ -8,11 +8,9 @@ process MANTA_SOMATIC { 'quay.io/biocontainers/manta:1.6.0--h9ee0642_1' }" input: - tuple val(meta), path(input_normal), path(input_index_normal), path(input_tumor), path(input_index_tumor) + tuple val(meta), path(input_normal), path(input_index_normal), path(input_tumor), path(input_index_tumor), path(target_bed), path(target_bed_tbi) path fasta path fai - path target_bed - path target_bed_tbi output: tuple val(meta), path("*.candidate_small_indels.vcf.gz") , emit: candidate_small_indels_vcf diff --git a/modules/manta/somatic/meta.yml b/modules/manta/somatic/meta.yml index ec9cc869..457d66a5 100644 --- a/modules/manta/somatic/meta.yml +++ b/modules/manta/somatic/meta.yml @@ -39,14 +39,6 @@ input: type: file description: BAM/CRAM/SAM index file pattern: "*.{bai,crai,sai}" - - fasta: - type: file - description: Genome reference FASTA file - pattern: "*.{fa,fasta}" - - fai: - type: file - description: Genome reference FASTA index file - pattern: "*.{fa.fai,fasta.fai}" - target_bed: type: file description: BED file containing target regions for variant calling @@ -55,6 +47,14 @@ input: type: file description: Index for BED file containing target regions for variant calling pattern: "*.{bed.tbi}" + - fasta: + type: file + description: Genome reference FASTA file + pattern: "*.{fa,fasta}" + - fai: + type: file + description: Genome reference FASTA index file + pattern: "*.{fa.fai,fasta.fai}" output: - meta: diff --git a/modules/manta/tumoronly/main.nf b/modules/manta/tumoronly/main.nf index 3d52b16e..3361cf82 100644 --- a/modules/manta/tumoronly/main.nf +++ b/modules/manta/tumoronly/main.nf @@ -8,11 +8,9 @@ process MANTA_TUMORONLY { 'quay.io/biocontainers/manta:1.6.0--h9ee0642_1' }" input: - tuple val(meta), path(input), path(input_index) + tuple val(meta), path(input), path(input_index), path(target_bed), path(target_bed_tbi) path fasta path fai - path target_bed - path target_bed_tbi output: tuple val(meta), path("*candidate_small_indels.vcf.gz") , emit: candidate_small_indels_vcf diff --git a/modules/manta/tumoronly/meta.yml b/modules/manta/tumoronly/meta.yml index f902bc77..398d6843 100644 --- a/modules/manta/tumoronly/meta.yml +++ b/modules/manta/tumoronly/meta.yml @@ -31,14 +31,6 @@ input: type: file description: BAM/CRAM/SAM index file pattern: "*.{bai,crai,sai}" - - fasta: - type: file - description: Genome reference FASTA file - pattern: "*.{fa,fasta}" - - fai: - type: file - description: Genome reference FASTA index file - pattern: "*.{fa.fai,fasta.fai}" - target_bed: type: file description: BED file containing target regions for variant calling @@ -47,6 +39,14 @@ input: type: file description: Index for BED file containing target regions for variant calling pattern: "*.{bed.tbi}" + - fasta: + type: file + description: Genome reference FASTA file + pattern: "*.{fa,fasta}" + - fai: + type: file + description: Genome reference FASTA index file + pattern: "*.{fa.fai,fasta.fai}" output: - meta: diff --git a/modules/mobsuite/recon/meta.yml b/modules/mobsuite/recon/meta.yml index b5232142..ef77e1e0 100644 --- a/modules/mobsuite/recon/meta.yml +++ b/modules/mobsuite/recon/meta.yml @@ -10,7 +10,7 @@ tools: documentation: https://github.com/phac-nml/mob-suite tool_dev_url: https://github.com/phac-nml/mob-suite doi: "10.1099/mgen.0.000435" - licence: ['Apache License, Version 2.0'] + licence: ["Apache License, Version 2.0"] input: - meta: diff --git a/modules/msisensorpro/msi_somatic/meta.yml b/modules/msisensorpro/msi_somatic/meta.yml index 09bc0e73..7caa1c1a 100644 --- a/modules/msisensorpro/msi_somatic/meta.yml +++ b/modules/msisensorpro/msi_somatic/meta.yml @@ -12,7 +12,7 @@ tools: documentation: https://github.com/xjtu-omics/msisensor-pro/wiki tool_dev_url: https://github.com/xjtu-omics/msisensor-pro doi: "doi.org/10.1016/j.gpb.2020.02.001" - licence: ['Custom Licence'] + licence: ["Custom Licence"] input: - meta: diff --git a/modules/msisensorpro/scan/meta.yml b/modules/msisensorpro/scan/meta.yml index 72c1b84b..27f5bc0f 100644 --- a/modules/msisensorpro/scan/meta.yml +++ b/modules/msisensorpro/scan/meta.yml @@ -11,7 +11,7 @@ tools: documentation: https://github.com/xjtu-omics/msisensor-pro/wiki tool_dev_url: https://github.com/xjtu-omics/msisensor-pro doi: "doi.org/10.1016/j.gpb.2020.02.001" - licence: ['Custom Licence'] + licence: ["Custom Licence"] input: - meta: diff --git a/modules/ngscheckmate/ncm/meta.yml b/modules/ngscheckmate/ncm/meta.yml index b8837b80..7f91f387 100644 --- a/modules/ngscheckmate/ncm/meta.yml +++ b/modules/ngscheckmate/ncm/meta.yml @@ -11,7 +11,7 @@ tools: documentation: https://github.com/parklab/NGSCheckMate tool_dev_url: https://github.com/parklab/NGSCheckMate doi: "doi:/10.1093/nar/gkx193" - licence: ['MIT'] + licence: ["MIT"] input: - files: diff --git a/modules/picard/addorreplacereadgroups/meta.yml b/modules/picard/addorreplacereadgroups/meta.yml index bdb5725c..e013bf4b 100644 --- a/modules/picard/addorreplacereadgroups/meta.yml +++ b/modules/picard/addorreplacereadgroups/meta.yml @@ -12,7 +12,7 @@ tools: homepage: https://broadinstitute.github.io/picard/ documentation: https://gatk.broadinstitute.org/hc/en-us/articles/360037226472-AddOrReplaceReadGroups-Picard- tool_dev_url: https://github.com/broadinstitute/picard - licence: ['MIT'] + licence: ["MIT"] input: - meta: diff --git a/modules/picard/createsequencedictionary/meta.yml b/modules/picard/createsequencedictionary/meta.yml index f40a4dbc..9510c590 100644 --- a/modules/picard/createsequencedictionary/meta.yml +++ b/modules/picard/createsequencedictionary/meta.yml @@ -7,11 +7,11 @@ keywords: tools: - picard: description: | - Creates a sequence dictionary file (with ".dict" extension) from a reference sequence provided in FASTA format, which is required by many processing and analysis tools. The output file contains a header but no SAMRecords, and the header contains only sequence records. + Creates a sequence dictionary file (with ".dict" extension) from a reference sequence provided in FASTA format, which is required by many processing and analysis tools. The output file contains a header but no SAMRecords, and the header contains only sequence records. homepage: https://broadinstitute.github.io/picard/ documentation: https://gatk.broadinstitute.org/hc/en-us/articles/360036712531-CreateSequenceDictionary-Picard- tool_dev_url: https://github.com/broadinstitute/picard - licence: ['MIT'] + licence: ["MIT"] input: - meta: diff --git a/modules/picard/fixmateinformation/meta.yml b/modules/picard/fixmateinformation/meta.yml index c01d803c..67dedcfa 100644 --- a/modules/picard/fixmateinformation/meta.yml +++ b/modules/picard/fixmateinformation/meta.yml @@ -10,7 +10,7 @@ tools: homepage: https://broadinstitute.github.io/picard/ documentation: https://gatk.broadinstitute.org/hc/en-us/articles/360036713471-FixMateInformation-Picard- tool_dev_url: https://github.com/broadinstitute/picard - licence: ['MIT'] + licence: ["MIT"] input: - meta: diff --git a/modules/picard/sortvcf/meta.yml b/modules/picard/sortvcf/meta.yml index a2b46d5a..f75d3401 100644 --- a/modules/picard/sortvcf/meta.yml +++ b/modules/picard/sortvcf/meta.yml @@ -8,7 +8,7 @@ tools: description: Java tools for working with NGS data in the BAM/CRAM/SAM and VCF format homepage: https://broadinstitute.github.io/picard/ documentation: https://broadinstitute.github.io/picard/command-line-overview.html#SortVcf - licence: ['MIT'] + licence: ["MIT"] input: - meta: diff --git a/modules/plink2/score/meta.yml b/modules/plink2/score/meta.yml index 5dad6259..be5fdbee 100644 --- a/modules/plink2/score/meta.yml +++ b/modules/plink2/score/meta.yml @@ -6,13 +6,13 @@ keywords: tools: - plink2: description: | - Whole genome association analysis toolset, designed to perform a range - of basic, large-scale analyses in a computationally efficient manner + Whole genome association analysis toolset, designed to perform a range + of basic, large-scale analyses in a computationally efficient manner homepage: http://www.cog-genomics.org/plink/2.0/ documentation: http://www.cog-genomics.org/plink/2.0/general_usage tool_dev_url: None doi: "10.1186/s13742-015-0047-8" - licence: ['GPL v3'] + licence: ["GPL v3"] input: - meta: diff --git a/modules/rgi/main/meta.yml b/modules/rgi/main/meta.yml index cd97ff92..1f0cb10d 100644 --- a/modules/rgi/main/meta.yml +++ b/modules/rgi/main/meta.yml @@ -11,7 +11,7 @@ tools: documentation: https://github.com/arpcard/rgi tool_dev_url: https://github.com/arpcard/rgi doi: "10.1093/nar/gkz935" - licence: ['https://card.mcmaster.ca/about'] + licence: ["https://card.mcmaster.ca/about"] input: - meta: diff --git a/modules/rsem/calculateexpression/meta.yml b/modules/rsem/calculateexpression/meta.yml index 10b54b49..8b89c7d1 100644 --- a/modules/rsem/calculateexpression/meta.yml +++ b/modules/rsem/calculateexpression/meta.yml @@ -11,7 +11,7 @@ tools: homepage: https://github.com/deweylab/RSEM documentation: https://github.com/deweylab/RSEM doi: https://doi.org/10.1186/1471-2105-12-323 - licence: ['GPL-3.0-or-later'] + licence: ["GPL-3.0-or-later"] input: - meta: type: map diff --git a/modules/seqkit/pair/meta.yml b/modules/seqkit/pair/meta.yml index 3b35d908..955cfbf2 100644 --- a/modules/seqkit/pair/meta.yml +++ b/modules/seqkit/pair/meta.yml @@ -10,7 +10,7 @@ tools: documentation: https://bioinf.shenwei.me/seqkit/usage/ tool_dev_url: https://github.com/shenwei356/seqkit/ doi: "10.1371/journal.pone.0163962" - licence: ['MIT'] + licence: ["MIT"] input: - meta: diff --git a/modules/seqtk/rename/meta.yml b/modules/seqtk/rename/meta.yml index b68dec8e..7672983c 100644 --- a/modules/seqtk/rename/meta.yml +++ b/modules/seqtk/rename/meta.yml @@ -8,7 +8,7 @@ tools: homepage: https://github.com/lh3/seqtk documentation: https://docs.csc.fi/apps/seqtk/ tool_dev_url: https://github.com/lh3/seqtk - licence: ['MIT'] + licence: ["MIT"] input: - meta: diff --git a/modules/seqtk/seq/meta.yml b/modules/seqtk/seq/meta.yml index ac32162b..3986257a 100644 --- a/modules/seqtk/seq/meta.yml +++ b/modules/seqtk/seq/meta.yml @@ -8,7 +8,7 @@ tools: homepage: https://github.com/lh3/seqtk documentation: https://docs.csc.fi/apps/seqtk/ tool_dev_url: https://github.com/lh3/seqtk - licence: ['MIT'] + licence: ["MIT"] input: - meta: diff --git a/modules/sistr/meta.yml b/modules/sistr/meta.yml index 5ce43334..db8399f6 100644 --- a/modules/sistr/meta.yml +++ b/modules/sistr/meta.yml @@ -11,7 +11,7 @@ tools: documentation: https://github.com/phac-nml/sistr_cmd tool_dev_url: https://github.com/phac-nml/sistr_cmd doi: "10.1371/journal.pone.0147101" - licence: ['Apache-2.0'] + licence: ["Apache-2.0"] input: - meta: diff --git a/modules/sourmash/sketch/meta.yml b/modules/sourmash/sketch/meta.yml index 9fb552bc..083774b5 100644 --- a/modules/sourmash/sketch/meta.yml +++ b/modules/sourmash/sketch/meta.yml @@ -10,7 +10,7 @@ tools: documentation: https://sourmash.readthedocs.io/ tool_dev_url: https://github.com/dib-lab/sourmash doi: "10.1186/s13059-016-0997-x" - licence: ['BSD-3-clause'] + licence: ["BSD-3-clause"] input: - meta: diff --git a/modules/ssuissero/meta.yml b/modules/ssuissero/meta.yml index 2c0031e6..8418e049 100644 --- a/modules/ssuissero/meta.yml +++ b/modules/ssuissero/meta.yml @@ -11,7 +11,7 @@ tools: documentation: https://github.com/jimmyliu1326/SsuisSero tool_dev_url: https://github.com/jimmyliu1326/SsuisSero doi: "" - licence: ['MIT'] + licence: ["MIT"] input: - meta: diff --git a/modules/stranger/meta.yml b/modules/stranger/meta.yml index a9a280ad..61ebc7a9 100644 --- a/modules/stranger/meta.yml +++ b/modules/stranger/meta.yml @@ -12,7 +12,7 @@ tools: documentation: https://github.com/moonso/stranger tool_dev_url: https://github.com/moonso/stranger doi: "10.5281/zenodo.4548873" - licence: ['MIT'] + licence: ["MIT"] input: - meta: diff --git a/modules/umitools/dedup/main.nf b/modules/umitools/dedup/main.nf index 1e46a612..dfcbcf2f 100644 --- a/modules/umitools/dedup/main.nf +++ b/modules/umitools/dedup/main.nf @@ -11,8 +11,11 @@ process UMITOOLS_DEDUP { tuple val(meta), path(bam), path(bai) output: - tuple val(meta), path("*.bam"), emit: bam - path "versions.yml" , emit: versions + tuple val(meta), path("*.bam") , emit: bam + tuple val(meta), path("*edit_distance.tsv"), emit: tsv_edit_distance + tuple val(meta), path("*per_umi.tsv") , emit: tsv_per_umi + tuple val(meta), path("*per_position.tsv") , emit: tsv_umi_per_position + path "versions.yml" , emit: versions when: task.ext.when == null || task.ext.when @@ -20,11 +23,13 @@ process UMITOOLS_DEDUP { script: def args = task.ext.args ?: '' def prefix = task.ext.prefix ?: "${meta.id}" - def paired = meta.single_end ? "" : "--paired" + def paired = meta.single_end ? "" : "--paired" """ - umi_tools dedup \\ + umi_tools \\ + dedup \\ -I $bam \\ -S ${prefix}.bam \\ + --output-stats $prefix \\ $paired \\ $args diff --git a/modules/umitools/dedup/meta.yml b/modules/umitools/dedup/meta.yml index 2038b40d..eee8952f 100644 --- a/modules/umitools/dedup/meta.yml +++ b/modules/umitools/dedup/meta.yml @@ -36,6 +36,18 @@ output: type: file description: BAM file with deduplicated UMIs. pattern: "*.{bam}" + - tsv_edit_distance: + type: file + description: Reports the (binned) average edit distance between the UMIs at each position. + pattern: "*edit_distance.tsv" + - tsv_per_umi: + type: file + description: UMI-level summary statistics. + pattern: "*per_umi.tsv" + - tsv_umi_per_position: + type: file + description: Tabulates the counts for unique combinations of UMI and position. + pattern: "*per_position.tsv" - versions: type: file description: File containing software versions diff --git a/modules/yara/index/meta.yml b/modules/yara/index/meta.yml index bdd6bf9a..bfc74f0a 100644 --- a/modules/yara/index/meta.yml +++ b/modules/yara/index/meta.yml @@ -13,10 +13,7 @@ tools: documentation: https://github.com/seqan/seqan tool_dev_url: https://github.com/seqan/seqan doi: "" - licence: - [ - "https://raw.githubusercontent.com/seqan/seqan/develop/apps/yara/LICENSE", - ] + licence: ["https://raw.githubusercontent.com/seqan/seqan/develop/apps/yara/LICENSE"] input: - fasta: diff --git a/modules/yara/mapper/meta.yml b/modules/yara/mapper/meta.yml index 188e1d52..0c4c0d43 100644 --- a/modules/yara/mapper/meta.yml +++ b/modules/yara/mapper/meta.yml @@ -11,10 +11,7 @@ tools: documentation: https://github.com/seqan/seqan tool_dev_url: https://github.com/seqan/seqan doi: "" - licence: - [ - "https://raw.githubusercontent.com/seqan/seqan/develop/apps/yara/LICENSE", - ] + licence: ["https://raw.githubusercontent.com/seqan/seqan/develop/apps/yara/LICENSE"] input: - meta: diff --git a/pytest.ini b/pytest.ini new file mode 100644 index 00000000..02a8acac --- /dev/null +++ b/pytest.ini @@ -0,0 +1,3 @@ +[pytest] +filterwarnings = + ignore::pytest.PytestRemovedIn8Warning:_pytest.nodes:140 diff --git a/tests/config/pytest_modules.yml b/tests/config/pytest_modules.yml index 48c3bb7d..ea17ce2e 100644 --- a/tests/config/pytest_modules.yml +++ b/tests/config/pytest_modules.yml @@ -202,6 +202,10 @@ bedtools/subtract: - modules/bedtools/subtract/** - tests/modules/bedtools/subtract/** +biobambam/bammarkduplicates2: + - modules/biobambam/bammarkduplicates2/** + - tests/modules/biobambam/bammarkduplicates2/** + biscuit/align: - modules/biscuit/index/** - modules/biscuit/align/** @@ -245,10 +249,6 @@ biscuit/vcf2bed: - modules/biscuit/vcf2bed/** - tests/modules/biscuit/vcf2bed/** -biobambam/bammarkduplicates2: - - modules/biobambam/bammarkduplicates2/** - - tests/modules/biobambam/bammarkduplicates2/** - bismark/align: - modules/bismark/align/** - modules/bismark/genomepreparation/** @@ -379,6 +379,10 @@ cellranger/mkref: - modules/cellranger/gtf/** - tests/modules/cellranger/gtf/** +centrifuge: + - modules/centrifuge/** + - tests/modules/centrifuge/** + checkm/lineagewf: - modules/checkm/lineagewf/** - tests/modules/checkm/lineagewf/** diff --git a/tests/modules/centrifuge/main.nf b/tests/modules/centrifuge/main.nf new file mode 100644 index 00000000..a8eb2fcb --- /dev/null +++ b/tests/modules/centrifuge/main.nf @@ -0,0 +1,33 @@ +#!/usr/bin/env nextflow + +nextflow.enable.dsl = 2 + +include { CENTRIFUGE } from '../../../modules/centrifuge/main.nf' + +workflow test_centrifuge_single_end { + input = [ [ id:'test', single_end:true ], // meta map + [ file(params.test_data['sarscov2']['illumina']['test_1_fastq_gz'], checkIfExists: true) ] + ] + db = file("https://raw.githubusercontent.com/nf-core/test-datasets/modules/data/delete_me/minigut_cf.tar.gz", checkIfExists: true) + save_unaligned = true + save_aligned = false + sam_format = false + + CENTRIFUGE ( input, db, save_unaligned, save_aligned, sam_format ) + +} + +workflow test_centrifuge_paired_end { + input = [ [ id:'test', single_end:false ], // meta map + [ file(params.test_data['sarscov2']['illumina']['test_1_fastq_gz'], checkIfExists: true), + file(params.test_data['sarscov2']['illumina']['test_2_fastq_gz'], checkIfExists: true) ] + ] + db = file("https://raw.githubusercontent.com/nf-core/test-datasets/modules/data/delete_me/minigut_cf.tar.gz", checkIfExists: true) + save_unaligned = true + save_aligned = false + sam_format = false + + CENTRIFUGE ( input, db, save_unaligned, save_aligned, sam_format ) + + +} diff --git a/tests/modules/centrifuge/nextflow.config b/tests/modules/centrifuge/nextflow.config new file mode 100644 index 00000000..50f50a7a --- /dev/null +++ b/tests/modules/centrifuge/nextflow.config @@ -0,0 +1,5 @@ +process { + + publishDir = { "${params.outdir}/${task.process.tokenize(':')[-1].tokenize('_')[0].toLowerCase()}" } + +} \ No newline at end of file diff --git a/tests/modules/centrifuge/test.yml b/tests/modules/centrifuge/test.yml new file mode 100644 index 00000000..a7b4360b --- /dev/null +++ b/tests/modules/centrifuge/test.yml @@ -0,0 +1,22 @@ +- name: centrifuge test_centrifuge_single_end + command: nextflow run tests/modules/centrifuge -entry test_centrifuge_single_end -c tests/config/nextflow.config + tags: + - centrifuge + files: + - path: output/centrifuge/test.kreport.txt + - path: output/centrifuge/test.report.txt + - path: output/centrifuge/test.results.txt + - path: output/centrifuge/test.unmapped.fastq.gz + - path: output/centrifuge/versions.yml + +- name: centrifuge test_centrifuge_paired_end + command: nextflow run tests/modules/centrifuge -entry test_centrifuge_paired_end -c tests/config/nextflow.config + tags: + - centrifuge + files: + - path: output/centrifuge/test.kreport.txt + - path: output/centrifuge/test.report.txt + - path: output/centrifuge/test.results.txt + - path: output/centrifuge/test.unmapped.fastq.1.gz + - path: output/centrifuge/test.unmapped.fastq.2.gz + - path: output/centrifuge/versions.yml diff --git a/tests/modules/deeparg/downloaddata/main.nf b/tests/modules/deeparg/downloaddata/main.nf index ed2d48bb..1074b0bc 100644 --- a/tests/modules/deeparg/downloaddata/main.nf +++ b/tests/modules/deeparg/downloaddata/main.nf @@ -5,5 +5,5 @@ nextflow.enable.dsl = 2 include { DEEPARG_DOWNLOADDATA } from '../../../../modules/deeparg/downloaddata/main.nf' workflow test_deeparg_downloaddata { - DEEPARG_DOWNLOADDATA () + DEEPARG_DOWNLOADDATA ( ) } diff --git a/tests/modules/deeparg/predict/main.nf b/tests/modules/deeparg/predict/main.nf index 2758ab58..2ada2374 100644 --- a/tests/modules/deeparg/predict/main.nf +++ b/tests/modules/deeparg/predict/main.nf @@ -13,7 +13,7 @@ workflow test_deeparg_predict { 'LS' ] - DEEPARG_DOWNLOADDATA() + DEEPARG_DOWNLOADDATA( ) DEEPARG_PREDICT ( input, DEEPARG_DOWNLOADDATA.out.db ) } diff --git a/tests/modules/gatk4/combinegvcfs/test.yml b/tests/modules/gatk4/combinegvcfs/test.yml index 72d8a6a5..54948668 100644 --- a/tests/modules/gatk4/combinegvcfs/test.yml +++ b/tests/modules/gatk4/combinegvcfs/test.yml @@ -5,6 +5,6 @@ - gatk4/combinegvcfs files: - path: output/gatk4/test.combined.g.vcf.gz - contains: ['VCFv4.2'] + contains: ["VCFv4.2"] - path: output/gatk4/versions.yml md5sum: 49d9c467f84b6a99a4da3ef161af26bd diff --git a/tests/modules/gatk4/genotypegvcfs/test.yml b/tests/modules/gatk4/genotypegvcfs/test.yml index a49673fd..dff79460 100644 --- a/tests/modules/gatk4/genotypegvcfs/test.yml +++ b/tests/modules/gatk4/genotypegvcfs/test.yml @@ -57,10 +57,7 @@ - gatk4/genotypegvcfs files: - path: output/gatk4/test.genotyped.vcf.gz - contains: - [ - "AC=2;AF=1.00;AN=2;DB;DP=20;ExcessHet=0.0000;FS=0.000;MLEAC=2;MLEAF=1.00;MQ=60.00;QD=24.05;SOR=0.693", - ] + contains: ["AC=2;AF=1.00;AN=2;DB;DP=20;ExcessHet=0.0000;FS=0.000;MLEAC=2;MLEAF=1.00;MQ=60.00;QD=24.05;SOR=0.693"] - path: output/gatk4/test.genotyped.vcf.gz.tbi - name: gatk4 genotypegvcfs test_gatk4_genotypegvcfs_gendb_input @@ -109,8 +106,5 @@ - gatk4/genotypegvcfs files: - path: output/gatk4/test.genotyped.vcf.gz - contains: - [ - "AC=2;AF=1.00;AN=2;DP=2;ExcessHet=0.0000;FS=0.000;MLEAC=1;MLEAF=0.500;MQ=60.00;QD=18.66;SOR=0.693", - ] + contains: ["AC=2;AF=1.00;AN=2;DP=2;ExcessHet=0.0000;FS=0.000;MLEAC=1;MLEAF=0.500;MQ=60.00;QD=18.66;SOR=0.693"] - path: output/gatk4/test.genotyped.vcf.gz.tbi diff --git a/tests/modules/hmmer/hmmsearch/test.yml b/tests/modules/hmmer/hmmsearch/test.yml index 91e4775c..dd3e16ef 100644 --- a/tests/modules/hmmer/hmmsearch/test.yml +++ b/tests/modules/hmmer/hmmsearch/test.yml @@ -6,7 +6,7 @@ files: - path: output/hmmer/test.txt.gz contains: - - '[ok]' + - "[ok]" - path: output/hmmer/versions.yml md5sum: ed0808c10abd205c6bd0fb01f45259bb @@ -20,12 +20,12 @@ md5sum: d3121aa33455074c566fb7f8fdcda7b0 - path: output/hmmer/test.domtbl.gz contains: - - '# [ok]' + - "# [ok]" - path: output/hmmer/test.tbl.gz contains: - - '# [ok]' + - "# [ok]" - path: output/hmmer/test.txt.gz contains: - - '[ok]' + - "[ok]" - path: output/hmmer/versions.yml md5sum: ebdcb08ae540e840f7b5c4c75a3a2993 diff --git a/tests/modules/ichorcna/createpon/test.yml b/tests/modules/ichorcna/createpon/test.yml index 53422b78..c8fe63c8 100644 --- a/tests/modules/ichorcna/createpon/test.yml +++ b/tests/modules/ichorcna/createpon/test.yml @@ -5,7 +5,7 @@ - ichorcna files: - path: output/ichorcna/PoN_median.txt - contains: ['seqnames'] + contains: ["seqnames"] - path: output/ichorcna/versions.yml md5sum: 59a2121301113cc013bfae65935e07f1 @@ -16,6 +16,6 @@ - ichorcna files: - path: output/ichorcna/PoN_median.txt - contains: ['seqnames'] + contains: ["seqnames"] - path: output/ichorcna/versions.yml md5sum: 31a5fcc0075dbe747f7736efbdb99644 diff --git a/tests/modules/ichorcna/run/test.yml b/tests/modules/ichorcna/run/test.yml index af78e4b3..4be83774 100644 --- a/tests/modules/ichorcna/run/test.yml +++ b/tests/modules/ichorcna/run/test.yml @@ -5,7 +5,7 @@ - ichorcna/run files: - path: output/ichorcna/test.cna.seg - contains: ['Corrected_Copy_Number'] + contains: ["Corrected_Copy_Number"] - path: output/ichorcna/test.params.txt md5sum: e39a579cdcc9576679f06dc5c22605a7 - path: output/ichorcna/versions.yml @@ -18,7 +18,7 @@ - ichorcna/run files: - path: output/ichorcna/test.cna.seg - contains: ['Corrected_Copy_Number'] + contains: ["Corrected_Copy_Number"] - path: output/ichorcna/test.params.txt md5sum: 0b97e0269cd0b571f5a85890f6ddb181 - path: output/ichorcna/versions.yml diff --git a/tests/modules/manta/germline/main.nf b/tests/modules/manta/germline/main.nf index bad62629..0081c29f 100644 --- a/tests/modules/manta/germline/main.nf +++ b/tests/modules/manta/germline/main.nf @@ -7,30 +7,28 @@ include { MANTA_GERMLINE } from '../../../../modules/manta/germline/main.nf' workflow test_manta_germline { input = [ [ id:'test'], // meta map - [ file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_cram'], checkIfExists: true)], - [ file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_cram_crai'], checkIfExists: true)] + file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_cram'], checkIfExists: true), + file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_cram_crai'], checkIfExists: true), + [],[] ] fasta = file(params.test_data['homo_sapiens']['genome']['genome_fasta'], checkIfExists: true) fai = file(params.test_data['homo_sapiens']['genome']['genome_fasta_fai'], checkIfExists: true) - bed = [[],[]] - MANTA_GERMLINE ( input, fasta, fai, bed ) + MANTA_GERMLINE ( input, fasta, fai ) } workflow test_manta_germline_target_bed { input = [ [ id:'test'], // meta map - [ file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_cram'], checkIfExists: true)], - [ file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_cram_crai'], checkIfExists: true)] + file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_cram'], checkIfExists: true), + file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_cram_crai'], checkIfExists: true), + file(params.test_data['homo_sapiens']['genome']['genome_bed_gz'], checkIfExists: true), + file(params.test_data['homo_sapiens']['genome']['genome_bed_gz_tbi'], checkIfExists: true) ] fasta = file(params.test_data['homo_sapiens']['genome']['genome_fasta'], checkIfExists: true) fai = file(params.test_data['homo_sapiens']['genome']['genome_fasta_fai'], checkIfExists: true) - bed = [ - file(params.test_data['homo_sapiens']['genome']['genome_bed_gz'], checkIfExists: true), - file(params.test_data['homo_sapiens']['genome']['genome_bed_gz_tbi'], checkIfExists: true), - ] - MANTA_GERMLINE ( input, fasta, fai, bed ) + MANTA_GERMLINE ( input, fasta, fai ) } workflow test_manta_germline_target_bed_jointcalling { @@ -39,14 +37,12 @@ workflow test_manta_germline_target_bed_jointcalling { [file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_cram'], checkIfExists: true), file(params.test_data['homo_sapiens']['illumina']['test2_paired_end_sorted_cram'], checkIfExists: true)], [file(params.test_data['homo_sapiens']['illumina']['test_paired_end_sorted_cram_crai'], checkIfExists: true), - file(params.test_data['homo_sapiens']['illumina']['test2_paired_end_sorted_cram_crai'], checkIfExists: true),] + file(params.test_data['homo_sapiens']['illumina']['test2_paired_end_sorted_cram_crai'], checkIfExists: true),], + file(params.test_data['homo_sapiens']['genome']['genome_bed_gz'], checkIfExists: true), + file(params.test_data['homo_sapiens']['genome']['genome_bed_gz_tbi'], checkIfExists: true) ] fasta = file(params.test_data['homo_sapiens']['genome']['genome_fasta'], checkIfExists: true) fai = file(params.test_data['homo_sapiens']['genome']['genome_fasta_fai'], checkIfExists: true) - bed = [ - file(params.test_data['homo_sapiens']['genome']['genome_bed_gz'], checkIfExists: true), - file(params.test_data['homo_sapiens']['genome']['genome_bed_gz_tbi'], checkIfExists: true), - ] - MANTA_GERMLINE ( input, fasta, fai, bed ) + MANTA_GERMLINE ( input, fasta, fai ) } diff --git a/tests/modules/manta/somatic/main.nf b/tests/modules/manta/somatic/main.nf index 7da41bea..b32a273e 100644 --- a/tests/modules/manta/somatic/main.nf +++ b/tests/modules/manta/somatic/main.nf @@ -11,13 +11,30 @@ workflow test_manta_somatic { file(params.test_data['homo_sapiens']['illumina']['test_paired_end_recalibrated_sorted_cram'], checkIfExists: true), file(params.test_data['homo_sapiens']['illumina']['test_paired_end_recalibrated_sorted_cram_crai'], checkIfExists: true), file(params.test_data['homo_sapiens']['illumina']['test2_paired_end_recalibrated_sorted_cram'], checkIfExists: true), - file(params.test_data['homo_sapiens']['illumina']['test2_paired_end_recalibrated_sorted_cram_crai'], checkIfExists: true) + file(params.test_data['homo_sapiens']['illumina']['test2_paired_end_recalibrated_sorted_cram_crai'], checkIfExists: true), + [], [] ] - fasta = file(params.test_data['homo_sapiens']['genome']['genome_fasta'], checkIfExists: true) - fai = file(params.test_data['homo_sapiens']['genome']['genome_fasta_fai'], checkIfExists: true) - bed = file(params.test_data['homo_sapiens']['genome']['genome_bed_gz'], checkIfExists: true) - bed_tbi = file(params.test_data['homo_sapiens']['genome']['genome_bed_gz_tbi'], checkIfExists: true) + fasta = file(params.test_data['homo_sapiens']['genome']['genome_21_fasta'], checkIfExists: true) + fai = file(params.test_data['homo_sapiens']['genome']['genome_21_fasta_fai'], checkIfExists: true) - MANTA_SOMATIC ( input, fasta, fai, bed, bed_tbi ) + MANTA_SOMATIC ( input, fasta, fai ) +} + +workflow test_manta_somatic_target_bed { + + input = [ + [ id:'test', single_end:false ], // meta map + file(params.test_data['homo_sapiens']['illumina']['test_paired_end_recalibrated_sorted_cram'], checkIfExists: true), + file(params.test_data['homo_sapiens']['illumina']['test_paired_end_recalibrated_sorted_cram_crai'], checkIfExists: true), + file(params.test_data['homo_sapiens']['illumina']['test2_paired_end_recalibrated_sorted_cram'], checkIfExists: true), + file(params.test_data['homo_sapiens']['illumina']['test2_paired_end_recalibrated_sorted_cram_crai'], checkIfExists: true), + file(params.test_data['homo_sapiens']['genome']['genome_21_multi_interval_bed_gz'], checkIfExists: true), + file(params.test_data['homo_sapiens']['genome']['genome_21_multi_interval_bed_gz_tbi'], checkIfExists: true), + ] + + fasta = file(params.test_data['homo_sapiens']['genome']['genome_21_fasta'], checkIfExists: true) + fai = file(params.test_data['homo_sapiens']['genome']['genome_21_fasta_fai'], checkIfExists: true) + + MANTA_SOMATIC ( input, fasta, fai ) } diff --git a/tests/modules/manta/tumoronly/main.nf b/tests/modules/manta/tumoronly/main.nf index be0d3dbb..dbe07914 100644 --- a/tests/modules/manta/tumoronly/main.nf +++ b/tests/modules/manta/tumoronly/main.nf @@ -8,28 +8,27 @@ workflow test_manta_tumoronly { input = [ [ id:'test'], // meta map file(params.test_data['homo_sapiens']['illumina']['test2_paired_end_recalibrated_sorted_cram'], checkIfExists: true), - file(params.test_data['homo_sapiens']['illumina']['test2_paired_end_recalibrated_sorted_cram_crai'], checkIfExists: true) + file(params.test_data['homo_sapiens']['illumina']['test2_paired_end_recalibrated_sorted_cram_crai'], checkIfExists: true), + [], [] ] - fasta = file(params.test_data['homo_sapiens']['genome']['genome_fasta'], checkIfExists: true) - fai = file(params.test_data['homo_sapiens']['genome']['genome_fasta_fai'], checkIfExists: true) - bed = [] - bed_tbi = [] + fasta = file(params.test_data['homo_sapiens']['genome']['genome_21_fasta'], checkIfExists: true) + fai = file(params.test_data['homo_sapiens']['genome']['genome_21_fasta_fai'], checkIfExists: true) - MANTA_TUMORONLY ( input, fasta, fai, bed, bed_tbi ) + MANTA_TUMORONLY ( input, fasta, fai ) } workflow test_manta_tumoronly_target_bed { input = [ [ id:'test'], // meta map file(params.test_data['homo_sapiens']['illumina']['test2_paired_end_recalibrated_sorted_cram'], checkIfExists: true), - file(params.test_data['homo_sapiens']['illumina']['test2_paired_end_recalibrated_sorted_cram_crai'], checkIfExists: true) + file(params.test_data['homo_sapiens']['illumina']['test2_paired_end_recalibrated_sorted_cram_crai'], checkIfExists: true), + file(params.test_data['homo_sapiens']['genome']['genome_21_multi_interval_bed_gz'], checkIfExists: true), + file(params.test_data['homo_sapiens']['genome']['genome_21_multi_interval_bed_gz_tbi'], checkIfExists: true) ] - fasta = file(params.test_data['homo_sapiens']['genome']['genome_fasta'], checkIfExists: true) - fai = file(params.test_data['homo_sapiens']['genome']['genome_fasta_fai'], checkIfExists: true) - bed = file(params.test_data['homo_sapiens']['genome']['genome_bed_gz'], checkIfExists: true) - bed_tbi = file(params.test_data['homo_sapiens']['genome']['genome_bed_gz_tbi'], checkIfExists: true) + fasta = file(params.test_data['homo_sapiens']['genome']['genome_21_fasta'], checkIfExists: true) + fai = file(params.test_data['homo_sapiens']['genome']['genome_21_fasta_fai'], checkIfExists: true) - MANTA_TUMORONLY ( input, fasta, fai, bed, bed_tbi ) + MANTA_TUMORONLY ( input, fasta, fai ) } diff --git a/tests/modules/picard/createsequencedictionary/test.yml b/tests/modules/picard/createsequencedictionary/test.yml index 3c9d0e7e..2a43be41 100644 --- a/tests/modules/picard/createsequencedictionary/test.yml +++ b/tests/modules/picard/createsequencedictionary/test.yml @@ -5,6 +5,6 @@ - picard files: - path: output/picard/test.dict - contains: ['SN:MT192765.1'] + contains: ["SN:MT192765.1"] - path: output/picard/versions.yml md5sum: b3d8c7ea65b8a6d3237b153d13fe2014 diff --git a/tests/modules/roary/test.yml b/tests/modules/roary/test.yml index 11bdf2c7..b6f02593 100644 --- a/tests/modules/roary/test.yml +++ b/tests/modules/roary/test.yml @@ -26,17 +26,14 @@ - path: output/roary/results/gene_presence_absence.Rtab contains: ["Gene"] - path: output/roary/results/gene_presence_absence.csv - contains: - [ - '"Gene","Non-unique Gene name","Annotation","No. isolates","No. sequences"', - ] + contains: ['"Gene","Non-unique Gene name","Annotation","No. isolates","No. sequences"'] - path: output/roary/results/number_of_conserved_genes.Rtab - contains: ["279"] + contains: ["2"] - path: output/roary/results/number_of_genes_in_pan_genome.Rtab - contains: ["279"] + contains: ["2"] - path: output/roary/results/number_of_new_genes.Rtab - contains: ["279"] + contains: ["2"] - path: output/roary/results/number_of_unique_genes.Rtab - contains: ["279"] + contains: ["2"] - path: output/roary/results/summary_statistics.txt md5sum: 3921b5445df6a7ed59408119b8860a58