diff --git a/CHANGELOG.md b/CHANGELOG.md index 188097ab..87031f64 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - The pipeline now stops on Busco failures (#194) - Update resource requirements for BLASTN modules (#191) and BLOBTOOLKIT_WINDOWSTATS - Fixed the `test_full` profile (Sanger only) +- Addition of `--tmpdir` to Diamond blast modules (#200) +- `--use_work_dir_as_temp` is no longer a hidden param. - Fixed some documentation (#193 and #197) - Made GENERATE_CONFIG more resilient to network errors (#197) diff --git a/conf/modules.config b/conf/modules.config index 87f686aa..a28287c3 100644 --- a/conf/modules.config +++ b/conf/modules.config @@ -105,11 +105,11 @@ process { } withName: "DIAMOND_BLASTP" { - ext.args = "--evalue 1.0e-25 --max-target-seqs 10 --max-hsps 1" + ext.args = { "--evalue 1.0e-25 --max-target-seqs 10 --max-hsps 1" + ( params.use_work_dir_as_temp ? " --tmpdir ./blastp_tmp/" : "" ) } } withName: "DIAMOND_BLASTX" { - ext.args = "--evalue 1.0e-25 --max-target-seqs 10 --max-hsps 1" + ext.args = { "--evalue 1.0e-25 --max-target-seqs 10 --max-hsps 1" + ( params.use_work_dir_as_temp ? " --tmpdir ./blastx_tmp/" : "" ) } } withName: "BLOBTK_DEPTH" { @@ -178,4 +178,3 @@ process { } } - diff --git a/modules/nf-core/diamond/blastp/diamond-blastp.diff b/modules/nf-core/diamond/blastp/diamond-blastp.diff index 12608ea0..7d0916da 100644 --- a/modules/nf-core/diamond/blastp/diamond-blastp.diff +++ b/modules/nf-core/diamond/blastp/diamond-blastp.diff @@ -1,4 +1,7 @@ -Changes in module 'nf-core/diamond/blastp' +Changes in component 'nf-core/diamond/blastp' +'modules/nf-core/diamond/blastp/meta.yml' is unchanged +'modules/nf-core/diamond/blastp/environment.yml' is unchanged +Changes in 'diamond/blastp/main.nf': --- modules/nf-core/diamond/blastp/main.nf +++ modules/nf-core/diamond/blastp/main.nf @@ -12,6 +12,7 @@ @@ -17,7 +20,16 @@ Changes in module 'nf-core/diamond/blastp' switch ( out_ext ) { case "blast": outfmt = 0; break case "xml": outfmt = 5; break -@@ -59,6 +61,7 @@ +@@ -51,6 +53,8 @@ + gzip -c -d ${fasta} > ${fasta_name} + fi + ++ mkdir -p ./blastp_tmp ++ + DB=`find -L ./ -name "*.dmnd" | sed 's/\\.dmnd\$//'` + + diamond \\ +@@ -59,6 +63,7 @@ --db \$DB \\ --query ${fasta_name} \\ --outfmt ${outfmt} ${columns} \\ @@ -26,4 +38,7 @@ Changes in module 'nf-core/diamond/blastp' --out ${prefix}.${out_ext} +'modules/nf-core/diamond/blastp/tests/main.nf.test' is unchanged +'modules/nf-core/diamond/blastp/tests/main.nf.test.snap' is unchanged +'modules/nf-core/diamond/blastp/tests/tags.yml' is unchanged ************************************************************ diff --git a/modules/nf-core/diamond/blastp/main.nf b/modules/nf-core/diamond/blastp/main.nf index ae5a1248..4d453763 100644 --- a/modules/nf-core/diamond/blastp/main.nf +++ b/modules/nf-core/diamond/blastp/main.nf @@ -53,6 +53,8 @@ process DIAMOND_BLASTP { gzip -c -d ${fasta} > ${fasta_name} fi + mkdir -p ./blastp_tmp + DB=`find -L ./ -name "*.dmnd" | sed 's/\\.dmnd\$//'` diamond \\ diff --git a/modules/nf-core/diamond/blastx/diamond-blastx.diff b/modules/nf-core/diamond/blastx/diamond-blastx.diff index eff4326a..5219a26f 100644 --- a/modules/nf-core/diamond/blastx/diamond-blastx.diff +++ b/modules/nf-core/diamond/blastx/diamond-blastx.diff @@ -1,4 +1,7 @@ -Changes in module 'nf-core/diamond/blastx' +Changes in component 'nf-core/diamond/blastx' +'modules/nf-core/diamond/blastx/meta.yml' is unchanged +'modules/nf-core/diamond/blastx/environment.yml' is unchanged +Changes in 'diamond/blastx/main.nf': --- modules/nf-core/diamond/blastx/main.nf +++ modules/nf-core/diamond/blastx/main.nf @@ -12,6 +12,7 @@ @@ -17,7 +20,16 @@ Changes in module 'nf-core/diamond/blastx' switch ( out_ext ) { case "blast": outfmt = 0; break case "xml": outfmt = 5; break -@@ -60,6 +62,7 @@ +@@ -52,6 +54,8 @@ + gzip -c -d ${fasta} > ${fasta_name} + fi + ++ mkdir -p ./blastx_tmp ++ + DB=`find -L ./ -name "*.dmnd" | sed 's/\\.dmnd\$//'` + + diamond \\ +@@ -60,6 +64,7 @@ --db \$DB \\ --query ${fasta_name} \\ --outfmt ${outfmt} ${columns} \\ @@ -26,4 +38,7 @@ Changes in module 'nf-core/diamond/blastx' --out ${prefix}.${out_ext} \\ --log +'modules/nf-core/diamond/blastx/tests/main.nf.test' is unchanged +'modules/nf-core/diamond/blastx/tests/main.nf.test.snap' is unchanged +'modules/nf-core/diamond/blastx/tests/tags.yml' is unchanged ************************************************************ diff --git a/modules/nf-core/diamond/blastx/main.nf b/modules/nf-core/diamond/blastx/main.nf index dfa82e24..d45c5d5d 100644 --- a/modules/nf-core/diamond/blastx/main.nf +++ b/modules/nf-core/diamond/blastx/main.nf @@ -54,6 +54,8 @@ process DIAMOND_BLASTX { gzip -c -d ${fasta} > ${fasta_name} fi + mkdir -p ./blastx_tmp + DB=`find -L ./ -name "*.dmnd" | sed 's/\\.dmnd\$//'` diamond \\ diff --git a/nextflow.config b/nextflow.config index c65219f9..bacd63d9 100644 --- a/nextflow.config +++ b/nextflow.config @@ -38,7 +38,7 @@ params { skip_taxon_filtering = false // Execution options - use_work_dir_as_temp = false + use_work_dir_as_temp = false // MultiQC options multiqc_config = null diff --git a/nextflow_schema.json b/nextflow_schema.json index 26724683..a6fbbcda 100644 --- a/nextflow_schema.json +++ b/nextflow_schema.json @@ -175,9 +175,9 @@ "properties": { "use_work_dir_as_temp": { "type": "boolean", - "description": "Set to true to make tools (e.g. sort, FastK, MerquryFK) use the work directory for their temporary files, rather than the system default.", + "description": "Set to true to make tools (e.g. sort, FastK, MerquryFK, BLASTP, BLASTX) use the work directory for their temporary files, rather than the system default.", "fa_icon": "fas fa-arrow-circle-down", - "hidden": true + "hidden": false } }, "fa_icon": "fas fa-running"