diff --git a/.github/snapshots/adaptivecard.nf.test.snap b/.github/snapshots/adaptivecard.nf.test.snap index 3ee6132d83..8de215fd4e 100644 --- a/.github/snapshots/adaptivecard.nf.test.snap +++ b/.github/snapshots/adaptivecard.nf.test.snap @@ -2,7 +2,14 @@ "-profile test": { "content": [ 4, - null, + { + "FASTQC": { + "fastqc": "0.12.1" + }, + "Workflow": { + "my-prefix/testpipeline": "v1.0.0dev" + } + }, [ "fastqc", "fastqc/SAMPLE1_PE_1_fastqc.html", diff --git a/.github/snapshots/changelog.nf.test.snap b/.github/snapshots/changelog.nf.test.snap index 8a5e05c858..98b73b4779 100644 --- a/.github/snapshots/changelog.nf.test.snap +++ b/.github/snapshots/changelog.nf.test.snap @@ -2,7 +2,14 @@ "-profile test": { "content": [ 4, - null, + { + "FASTQC": { + "fastqc": "0.12.1" + }, + "Workflow": { + "my-prefix/testpipeline": "v1.0.0dev" + } + }, [ "fastqc", "fastqc/SAMPLE1_PE_1_fastqc.html", diff --git a/.github/snapshots/ci.nf.test.snap b/.github/snapshots/ci.nf.test.snap index ce4a455ac3..61b7b49132 100644 --- a/.github/snapshots/ci.nf.test.snap +++ b/.github/snapshots/ci.nf.test.snap @@ -2,7 +2,14 @@ "-profile test": { "content": [ 4, - null, + { + "FASTQC": { + "fastqc": "0.12.1" + }, + "Workflow": { + "my-prefix/testpipeline": "v1.0.0dev" + } + }, [ "fastqc", "fastqc/SAMPLE1_PE_1_fastqc.html", diff --git a/.github/snapshots/citations.nf.test.snap b/.github/snapshots/citations.nf.test.snap index 6d7cecc8b5..fcf055e0cc 100644 --- a/.github/snapshots/citations.nf.test.snap +++ b/.github/snapshots/citations.nf.test.snap @@ -2,7 +2,14 @@ "-profile test": { "content": [ 4, - null, + { + "FASTQC": { + "fastqc": "0.12.1" + }, + "Workflow": { + "my-prefix/testpipeline": "v1.0.0dev" + } + }, [ "fastqc", "fastqc/SAMPLE1_PE_1_fastqc.html", diff --git a/.github/snapshots/code_linters.nf.test.snap b/.github/snapshots/code_linters.nf.test.snap index 6d7cecc8b5..fcf055e0cc 100644 --- a/.github/snapshots/code_linters.nf.test.snap +++ b/.github/snapshots/code_linters.nf.test.snap @@ -2,7 +2,14 @@ "-profile test": { "content": [ 4, - null, + { + "FASTQC": { + "fastqc": "0.12.1" + }, + "Workflow": { + "my-prefix/testpipeline": "v1.0.0dev" + } + }, [ "fastqc", "fastqc/SAMPLE1_PE_1_fastqc.html", diff --git a/.github/snapshots/codespaces.nf.test.snap b/.github/snapshots/codespaces.nf.test.snap index 6d7cecc8b5..fcf055e0cc 100644 --- a/.github/snapshots/codespaces.nf.test.snap +++ b/.github/snapshots/codespaces.nf.test.snap @@ -2,7 +2,14 @@ "-profile test": { "content": [ 4, - null, + { + "FASTQC": { + "fastqc": "0.12.1" + }, + "Workflow": { + "my-prefix/testpipeline": "v1.0.0dev" + } + }, [ "fastqc", "fastqc/SAMPLE1_PE_1_fastqc.html", diff --git a/.github/snapshots/documentation.nf.test.snap b/.github/snapshots/documentation.nf.test.snap index 3ee6132d83..8de215fd4e 100644 --- a/.github/snapshots/documentation.nf.test.snap +++ b/.github/snapshots/documentation.nf.test.snap @@ -2,7 +2,14 @@ "-profile test": { "content": [ 4, - null, + { + "FASTQC": { + "fastqc": "0.12.1" + }, + "Workflow": { + "my-prefix/testpipeline": "v1.0.0dev" + } + }, [ "fastqc", "fastqc/SAMPLE1_PE_1_fastqc.html", diff --git a/.github/snapshots/email.nf.test.snap b/.github/snapshots/email.nf.test.snap index 3ee6132d83..8de215fd4e 100644 --- a/.github/snapshots/email.nf.test.snap +++ b/.github/snapshots/email.nf.test.snap @@ -2,7 +2,14 @@ "-profile test": { "content": [ 4, - null, + { + "FASTQC": { + "fastqc": "0.12.1" + }, + "Workflow": { + "my-prefix/testpipeline": "v1.0.0dev" + } + }, [ "fastqc", "fastqc/SAMPLE1_PE_1_fastqc.html", diff --git a/.github/snapshots/fastqc.nf.test.snap b/.github/snapshots/fastqc.nf.test.snap index d91149e893..5ce3dec844 100644 --- a/.github/snapshots/fastqc.nf.test.snap +++ b/.github/snapshots/fastqc.nf.test.snap @@ -2,7 +2,11 @@ "-profile test": { "content": [ 1, - null, + { + "Workflow": { + "my-prefix/testpipeline": "v1.0.0dev" + } + }, [ "multiqc", "multiqc/multiqc_data", diff --git a/.github/snapshots/github_badges.nf.test.snap b/.github/snapshots/github_badges.nf.test.snap index cb8c64a661..ed83e9a3a7 100644 --- a/.github/snapshots/github_badges.nf.test.snap +++ b/.github/snapshots/github_badges.nf.test.snap @@ -2,7 +2,14 @@ "-profile test": { "content": [ 4, - null, + { + "FASTQC": { + "fastqc": "0.12.1" + }, + "Workflow": { + "my-prefix/testpipeline": "v1.0.0dev" + } + }, [ "fastqc", "fastqc/SAMPLE1_PE_1_fastqc.html", diff --git a/.github/snapshots/gitpod.nf.test.snap b/.github/snapshots/gitpod.nf.test.snap index 6d7cecc8b5..fcf055e0cc 100644 --- a/.github/snapshots/gitpod.nf.test.snap +++ b/.github/snapshots/gitpod.nf.test.snap @@ -2,7 +2,14 @@ "-profile test": { "content": [ 4, - null, + { + "FASTQC": { + "fastqc": "0.12.1" + }, + "Workflow": { + "my-prefix/testpipeline": "v1.0.0dev" + } + }, [ "fastqc", "fastqc/SAMPLE1_PE_1_fastqc.html", diff --git a/.github/snapshots/gpu.nf.test.snap b/.github/snapshots/gpu.nf.test.snap new file mode 100644 index 0000000000..eb56c28c62 --- /dev/null +++ b/.github/snapshots/gpu.nf.test.snap @@ -0,0 +1,116 @@ +{ + "-profile test": { + "content": [ + 4, + { + "FASTQC": { + "fastqc": "0.12.1" + }, + "Workflow": { + "my-prefix/testpipeline": "v1.0.0dev" + } + }, + [ + "fastqc", + "fastqc/SAMPLE1_PE_1_fastqc.html", + "fastqc/SAMPLE1_PE_1_fastqc.zip", + "fastqc/SAMPLE1_PE_2_fastqc.html", + "fastqc/SAMPLE1_PE_2_fastqc.zip", + "fastqc/SAMPLE2_PE_1_fastqc.html", + "fastqc/SAMPLE2_PE_1_fastqc.zip", + "fastqc/SAMPLE2_PE_2_fastqc.html", + "fastqc/SAMPLE2_PE_2_fastqc.zip", + "fastqc/SAMPLE3_SE_1_fastqc.html", + "fastqc/SAMPLE3_SE_1_fastqc.zip", + "fastqc/SAMPLE3_SE_2_fastqc.html", + "fastqc/SAMPLE3_SE_2_fastqc.zip", + "multiqc", + "multiqc/multiqc_data", + "multiqc/multiqc_data/fastqc-status-check-heatmap.txt", + "multiqc/multiqc_data/fastqc_overrepresented_sequences_plot.txt", + "multiqc/multiqc_data/fastqc_per_base_n_content_plot.txt", + "multiqc/multiqc_data/fastqc_per_base_sequence_quality_plot.txt", + "multiqc/multiqc_data/fastqc_per_sequence_gc_content_plot_Counts.txt", + "multiqc/multiqc_data/fastqc_per_sequence_gc_content_plot_Percentages.txt", + "multiqc/multiqc_data/fastqc_per_sequence_quality_scores_plot.txt", + "multiqc/multiqc_data/fastqc_sequence_counts_plot.txt", + "multiqc/multiqc_data/fastqc_sequence_duplication_levels_plot.txt", + "multiqc/multiqc_data/fastqc_sequence_length_distribution_plot.txt", + "multiqc/multiqc_data/fastqc_top_overrepresented_sequences_table.txt", + "multiqc/multiqc_data/multiqc.log", + "multiqc/multiqc_data/multiqc_citations.txt", + "multiqc/multiqc_data/multiqc_data.json", + "multiqc/multiqc_data/multiqc_fastqc.txt", + "multiqc/multiqc_data/multiqc_general_stats.txt", + "multiqc/multiqc_data/multiqc_software_versions.txt", + "multiqc/multiqc_data/multiqc_sources.txt", + "multiqc/multiqc_plots", + "multiqc/multiqc_plots/pdf", + "multiqc/multiqc_plots/pdf/fastqc-status-check-heatmap.pdf", + "multiqc/multiqc_plots/pdf/fastqc_overrepresented_sequences_plot.pdf", + "multiqc/multiqc_plots/pdf/fastqc_per_base_n_content_plot.pdf", + "multiqc/multiqc_plots/pdf/fastqc_per_base_sequence_quality_plot.pdf", + "multiqc/multiqc_plots/pdf/fastqc_per_sequence_gc_content_plot_Counts.pdf", + "multiqc/multiqc_plots/pdf/fastqc_per_sequence_gc_content_plot_Percentages.pdf", + "multiqc/multiqc_plots/pdf/fastqc_per_sequence_quality_scores_plot.pdf", + "multiqc/multiqc_plots/pdf/fastqc_sequence_counts_plot-cnt.pdf", + "multiqc/multiqc_plots/pdf/fastqc_sequence_counts_plot-pct.pdf", + "multiqc/multiqc_plots/pdf/fastqc_sequence_duplication_levels_plot.pdf", + "multiqc/multiqc_plots/pdf/fastqc_sequence_length_distribution_plot.pdf", + "multiqc/multiqc_plots/pdf/fastqc_top_overrepresented_sequences_table.pdf", + "multiqc/multiqc_plots/pdf/general_stats_table.pdf", + "multiqc/multiqc_plots/png", + "multiqc/multiqc_plots/png/fastqc-status-check-heatmap.png", + "multiqc/multiqc_plots/png/fastqc_overrepresented_sequences_plot.png", + "multiqc/multiqc_plots/png/fastqc_per_base_n_content_plot.png", + "multiqc/multiqc_plots/png/fastqc_per_base_sequence_quality_plot.png", + "multiqc/multiqc_plots/png/fastqc_per_sequence_gc_content_plot_Counts.png", + "multiqc/multiqc_plots/png/fastqc_per_sequence_gc_content_plot_Percentages.png", + "multiqc/multiqc_plots/png/fastqc_per_sequence_quality_scores_plot.png", + "multiqc/multiqc_plots/png/fastqc_sequence_counts_plot-cnt.png", + "multiqc/multiqc_plots/png/fastqc_sequence_counts_plot-pct.png", + "multiqc/multiqc_plots/png/fastqc_sequence_duplication_levels_plot.png", + "multiqc/multiqc_plots/png/fastqc_sequence_length_distribution_plot.png", + "multiqc/multiqc_plots/png/fastqc_top_overrepresented_sequences_table.png", + "multiqc/multiqc_plots/png/general_stats_table.png", + "multiqc/multiqc_plots/svg", + "multiqc/multiqc_plots/svg/fastqc-status-check-heatmap.svg", + "multiqc/multiqc_plots/svg/fastqc_overrepresented_sequences_plot.svg", + "multiqc/multiqc_plots/svg/fastqc_per_base_n_content_plot.svg", + "multiqc/multiqc_plots/svg/fastqc_per_base_sequence_quality_plot.svg", + "multiqc/multiqc_plots/svg/fastqc_per_sequence_gc_content_plot_Counts.svg", + "multiqc/multiqc_plots/svg/fastqc_per_sequence_gc_content_plot_Percentages.svg", + "multiqc/multiqc_plots/svg/fastqc_per_sequence_quality_scores_plot.svg", + "multiqc/multiqc_plots/svg/fastqc_sequence_counts_plot-cnt.svg", + "multiqc/multiqc_plots/svg/fastqc_sequence_counts_plot-pct.svg", + "multiqc/multiqc_plots/svg/fastqc_sequence_duplication_levels_plot.svg", + "multiqc/multiqc_plots/svg/fastqc_sequence_length_distribution_plot.svg", + "multiqc/multiqc_plots/svg/fastqc_top_overrepresented_sequences_table.svg", + "multiqc/multiqc_plots/svg/general_stats_table.svg", + "multiqc/multiqc_report.html", + "pipeline_info", + "pipeline_info/testpipeline_software_mqc_versions.yml" + ], + [ + "fastqc-status-check-heatmap.txt:md5,0f1975c565a16bf09be08a05c204ded7", + "fastqc_overrepresented_sequences_plot.txt:md5,4b23cea39c4e23deef6b97810bc1ee46", + "fastqc_per_base_n_content_plot.txt:md5,037692101c0130c72493d3bbfa3afac1", + "fastqc_per_base_sequence_quality_plot.txt:md5,bfe735f3e31befe13bdf6761bb297d6e", + "fastqc_per_sequence_gc_content_plot_Counts.txt:md5,7108d19c46ef7883e864ba274c457d2e", + "fastqc_per_sequence_gc_content_plot_Percentages.txt:md5,23f527c80a148e4f34e5a43f6e520a90", + "fastqc_per_sequence_quality_scores_plot.txt:md5,a0cc0e6df7bfb05257da1cfc88b13c50", + "fastqc_sequence_counts_plot.txt:md5,c6e4e1588e6765fe8df27812a1322fbd", + "fastqc_sequence_duplication_levels_plot.txt:md5,3cde2db4033f6c64648976d1174db925", + "fastqc_sequence_length_distribution_plot.txt:md5,e82b9b14a7e24c0c5f27af97cebb6870", + "multiqc_citations.txt:md5,4c806e63a283ec1b7e78cdae3a923d4f", + "multiqc_fastqc.txt:md5,1a41c2158adc9947bff9232962f70110", + "multiqc_general_stats.txt:md5,0b54e4e764665bd57fe0f95216744a78" + ] + ], + "meta": { + "nf-test": "0.9.2", + "nextflow": "24.10.5" + }, + "timestamp": "2025-06-16T14:29:10.076573" + } +} \ No newline at end of file diff --git a/.github/snapshots/igenomes.nf.test.snap b/.github/snapshots/igenomes.nf.test.snap index 8ca4448ccd..ce01d9d5d4 100644 --- a/.github/snapshots/igenomes.nf.test.snap +++ b/.github/snapshots/igenomes.nf.test.snap @@ -2,7 +2,14 @@ "-profile test": { "content": [ 4, - null, + { + "FASTQC": { + "fastqc": "0.12.1" + }, + "Workflow": { + "my-prefix/testpipeline": "v1.0.0dev" + } + }, [ "fastqc", "fastqc/SAMPLE1_PE_1_fastqc.html", diff --git a/.github/snapshots/license.nf.test.snap b/.github/snapshots/license.nf.test.snap index 3ee6132d83..8de215fd4e 100644 --- a/.github/snapshots/license.nf.test.snap +++ b/.github/snapshots/license.nf.test.snap @@ -2,7 +2,14 @@ "-profile test": { "content": [ 4, - null, + { + "FASTQC": { + "fastqc": "0.12.1" + }, + "Workflow": { + "my-prefix/testpipeline": "v1.0.0dev" + } + }, [ "fastqc", "fastqc/SAMPLE1_PE_1_fastqc.html", diff --git a/.github/snapshots/nf_core_configs.nf.test.snap b/.github/snapshots/nf_core_configs.nf.test.snap index 6d7cecc8b5..fcf055e0cc 100644 --- a/.github/snapshots/nf_core_configs.nf.test.snap +++ b/.github/snapshots/nf_core_configs.nf.test.snap @@ -2,7 +2,14 @@ "-profile test": { "content": [ 4, - null, + { + "FASTQC": { + "fastqc": "0.12.1" + }, + "Workflow": { + "my-prefix/testpipeline": "v1.0.0dev" + } + }, [ "fastqc", "fastqc/SAMPLE1_PE_1_fastqc.html", diff --git a/.github/snapshots/nf_schema.nf.test.snap b/.github/snapshots/nf_schema.nf.test.snap index d7a15c6252..bd6eb4e0cf 100644 --- a/.github/snapshots/nf_schema.nf.test.snap +++ b/.github/snapshots/nf_schema.nf.test.snap @@ -2,7 +2,14 @@ "-profile test": { "content": [ 4, - null, + { + "FASTQC": { + "fastqc": "0.12.1" + }, + "Workflow": { + "my-prefix/testpipeline": "v1.0.0dev" + } + }, [ "fastqc", "fastqc/SAMPLE1_PE_1_fastqc.html", diff --git a/.github/snapshots/rocrate.nf.test.snap b/.github/snapshots/rocrate.nf.test.snap index 3ee6132d83..8de215fd4e 100644 --- a/.github/snapshots/rocrate.nf.test.snap +++ b/.github/snapshots/rocrate.nf.test.snap @@ -2,7 +2,14 @@ "-profile test": { "content": [ 4, - null, + { + "FASTQC": { + "fastqc": "0.12.1" + }, + "Workflow": { + "my-prefix/testpipeline": "v1.0.0dev" + } + }, [ "fastqc", "fastqc/SAMPLE1_PE_1_fastqc.html", diff --git a/.github/snapshots/seqera_platform.nf.test.snap b/.github/snapshots/seqera_platform.nf.test.snap index 3ee6132d83..8de215fd4e 100644 --- a/.github/snapshots/seqera_platform.nf.test.snap +++ b/.github/snapshots/seqera_platform.nf.test.snap @@ -2,7 +2,14 @@ "-profile test": { "content": [ 4, - null, + { + "FASTQC": { + "fastqc": "0.12.1" + }, + "Workflow": { + "my-prefix/testpipeline": "v1.0.0dev" + } + }, [ "fastqc", "fastqc/SAMPLE1_PE_1_fastqc.html", diff --git a/.github/snapshots/slackreport.nf.test.snap b/.github/snapshots/slackreport.nf.test.snap index 3ee6132d83..8de215fd4e 100644 --- a/.github/snapshots/slackreport.nf.test.snap +++ b/.github/snapshots/slackreport.nf.test.snap @@ -2,7 +2,14 @@ "-profile test": { "content": [ 4, - null, + { + "FASTQC": { + "fastqc": "0.12.1" + }, + "Workflow": { + "my-prefix/testpipeline": "v1.0.0dev" + } + }, [ "fastqc", "fastqc/SAMPLE1_PE_1_fastqc.html", diff --git a/.github/snapshots/vscode.nf.test.snap b/.github/snapshots/vscode.nf.test.snap index 3ee6132d83..8de215fd4e 100644 --- a/.github/snapshots/vscode.nf.test.snap +++ b/.github/snapshots/vscode.nf.test.snap @@ -2,7 +2,14 @@ "-profile test": { "content": [ 4, - null, + { + "FASTQC": { + "fastqc": "0.12.1" + }, + "Workflow": { + "my-prefix/testpipeline": "v1.0.0dev" + } + }, [ "fastqc", "fastqc/SAMPLE1_PE_1_fastqc.html", diff --git a/.github/workflows/create-test-lint-wf-template.yml b/.github/workflows/create-test-lint-wf-template.yml index 8c025f5f97..8e4e633ddb 100644 --- a/.github/workflows/create-test-lint-wf-template.yml +++ b/.github/workflows/create-test-lint-wf-template.yml @@ -38,7 +38,8 @@ jobs: - name: Create Matrix id: create_matrix run: | - echo "matrix=$(yq 'keys | filter(. != "github") | filter(. != "is_nfcore") | filter(. != "test_config") | tojson(0)' nf_core/pipelines/create/template_features.yml)" >> $GITHUB_OUTPUT + echo "matrix=$(yq '.[].features | keys | filter(. != "github") | filter(. != "is_nfcore") | filter(. != "test_config")' nf_core/pipelines/create/template_features.yml | \ + yq 'flatten | tojson(0)' -)" >> $GITHUB_OUTPUT RunTestWorkflow: runs-on: diff --git a/CHANGELOG.md b/CHANGELOG.md index a68f8d4622..2bbe585874 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -106,6 +106,7 @@ We also enabled to install subworkflows with modules from different remotes. - Handling issue with arity #3530 ([#3539](https://github.com/nf-core/tools/pull/3539)) - GitHub action for nightly tests with Nextflow from source ([#3553](https://github.com/nf-core/tools/pull/3553)) - Update CI to test template pipelines with nf-test ([#3559](https://github.com/nf-core/tools/pull/3559)) +- Add opt-in feature `gpu` ([#3562](https://github.com/nf-core/tools/pull/3562)) - Use secret for notification email on nextflow nightly builds ([#3576](https://github.com/nf-core/tools/pull/3576)) - Use pdiff from setup-nf-test ([#3578](https://github.com/nf-core/tools/pull/3578)) diff --git a/log.txt b/log.txt deleted file mode 100644 index e69de29bb2..0000000000 diff --git a/nf_core/pipeline-template/tests/default.nf.test b/nf_core/pipeline-template/tests/default.nf.test index d0fe324a3a..a2eba5a782 100644 --- a/nf_core/pipeline-template/tests/default.nf.test +++ b/nf_core/pipeline-template/tests/default.nf.test @@ -23,7 +23,7 @@ nextflow_pipeline { // Number of successful tasks workflow.trace.succeeded().size(), // pipeline versions.yml file for multiqc from which Nextflow version is removed because we test pipelines on multiple Nextflow versions - removeNextflowVersion("$outputDir/pipeline_info/nf_core_{{ short_name }}_software_mqc_versions.yml"), + removeNextflowVersion("$outputDir/pipeline_info/{% if is_nfcore %}nf_core_{% endif %}{{ short_name }}_software_mqc_versions.yml"), // All stable path name, with a relative path stable_name, // All files with stable contents diff --git a/nf_core/pipelines/create/__init__.py b/nf_core/pipelines/create/__init__.py index a4d457d623..8b873eaa6c 100644 --- a/nf_core/pipelines/create/__init__.py +++ b/nf_core/pipelines/create/__init__.py @@ -104,7 +104,7 @@ def action_toggle_dark(self) -> None: def action_toggle_all(self) -> None: """An action to toggle all Switches.""" - switches = self.query(Switch) + switches = self.screen.query("Switch") if not switches: return # No Switches widgets found # Determine the new state based on the first switch diff --git a/nf_core/pipelines/create/create.py b/nf_core/pipelines/create/create.py index a370ee2391..c144586073 100644 --- a/nf_core/pipelines/create/create.py +++ b/nf_core/pipelines/create/create.py @@ -112,7 +112,15 @@ def __init__( self.template_features_yml = yaml.safe_load(rendered_features) # Get list of files we're skipping with the supplied skip keys - self.skip_paths = set(sp for k in self.skip_areas for sp in self.template_features_yml[k]["skippable_paths"]) + + skip_paths = [ + path + for feature in self.skip_areas + for section in self.template_features_yml.values() + if feature in section["features"] and section["features"][feature]["skippable_paths"] + for path in section["features"][feature]["skippable_paths"] + ] + self.skip_paths = set(skip_paths) # Set convenience variables self.name = self.config.name @@ -213,14 +221,20 @@ def obtain_jinja_params_dict( jinja_params = self.config.model_dump(exclude_none=True) # Add template areas to jinja params and create list of areas with paths to skip - skip_areas = [] - for t_area in self.template_features_yml.keys(): - if t_area in features_to_skip: - if self.template_features_yml[t_area]["skippable_paths"]: - skip_areas.append(t_area) - jinja_params[t_area] = False - else: - jinja_params[t_area] = True + skip_areas = [ + t_area + for section in self.template_features_yml.values() + for t_area in section["features"].keys() + if t_area in features_to_skip and section["features"][t_area]["skippable_paths"] + # for t_area in section["features"][t_area]["skippable_paths"] + ] + jinja_params.update( + { + t_area: t_area not in features_to_skip + for section in self.template_features_yml.values() + for t_area in section["features"] + } + ) # Add is_nfcore as an area to skip for non-nf-core pipelines, to skip all nf-core files if not self.config.is_nfcore: @@ -397,18 +411,20 @@ def fix_linting(self): """ # Create a lint config lint_config = {} - for area in (self.config.skip_features or []) + self.skip_areas: + for area in set((self.config.skip_features or []) + self.skip_areas): try: - for lint_test in self.template_features_yml[area]["linting"]: - try: - if self.template_features_yml[area]["linting"][lint_test]: - lint_config.setdefault(lint_test, []).extend( - self.template_features_yml[area]["linting"][lint_test] - ) - else: - lint_config[lint_test] = False - except AttributeError: - pass # When linting is False + for section_name in self.template_features_yml.keys(): + if area in self.template_features_yml[section_name]["features"]: + for lint_test in self.template_features_yml[section_name]["features"][area]["linting"]: + try: + if self.template_features_yml[section_name]["features"][area]["linting"][lint_test]: + lint_config.setdefault(lint_test, []).extend( + self.template_features_yml[section_name]["features"][area]["linting"][lint_test] + ) + else: + lint_config[lint_test] = False + except AttributeError: + pass # When linting is False except KeyError: pass # Areas without linting diff --git a/nf_core/pipelines/create/custompipeline.py b/nf_core/pipelines/create/custompipeline.py index e433db41ec..357cff8762 100644 --- a/nf_core/pipelines/create/custompipeline.py +++ b/nf_core/pipelines/create/custompipeline.py @@ -23,7 +23,7 @@ def compose(self) -> ComposeResult: ) ) yield Horizontal( - Switch(id="toggle_all", value=True), + Switch(id="toggle_all", value=False), Static("Toggle all features", classes="feature_title"), classes="custom_grid", ) @@ -36,12 +36,27 @@ def compose(self) -> ComposeResult: ) def on_mount(self) -> None: - for name, feature in self.parent.template_features_yml.items(): - if feature["custom_pipelines"]: - self.query_one("#features").mount( - PipelineFeature(feature["help_text"], feature["short_description"], feature["description"], name) - ) - self.query_one("#toggle_all", Switch).value = True + for section_name, section in self.parent.template_features_yml.items(): + section_title = "## " + section["name"] + features = section["features"] + show_section = False + self.query_one("#features").mount( + Markdown(section_title, id=section_name), + ) + for name, feature in features.items(): + if feature["custom_pipelines"]: + show_section = True + self.query_one("#features").mount( + PipelineFeature( + feature["help_text"], + feature["short_description"], + feature["description"], + name, + feature["default"], + ) + ) + if not show_section: + self.query_one("#features").query_one(f"#{section_name}").remove() @on(Button.Pressed, "#continue") def on_button_pressed(self, event: Button.Pressed) -> None: diff --git a/nf_core/pipelines/create/nfcorepipeline.py b/nf_core/pipelines/create/nfcorepipeline.py index ebb9866986..d86f236387 100644 --- a/nf_core/pipelines/create/nfcorepipeline.py +++ b/nf_core/pipelines/create/nfcorepipeline.py @@ -30,11 +30,27 @@ def compose(self) -> ComposeResult: ) def on_mount(self) -> None: - for name, feature in self.parent.template_features_yml.items(): - if feature["nfcore_pipelines"]: - self.query_one("#features").mount( - PipelineFeature(feature["help_text"], feature["short_description"], feature["description"], name) - ) + for section_name, section in self.parent.template_features_yml.items(): + section_title = section["name"] + features = section["features"] + show_section = False + self.query_one("#features").mount( + Markdown(section_title, id=section_name), + ) + for name, feature in features.items(): + if feature["nfcore_pipelines"]: + show_section = True + self.query_one("#features").mount( + PipelineFeature( + feature["help_text"], + feature["short_description"], + feature["description"], + name, + feature["default"], + ) + ) + if not show_section: + self.query_one("#features").query_one(f"#{section_name}").remove() @on(Button.Pressed, "#continue") def on_button_pressed(self, event: Button.Pressed) -> None: diff --git a/nf_core/pipelines/create/template_features.yml b/nf_core/pipelines/create/template_features.yml index a6fe8c51de..f052ac6e5b 100644 --- a/nf_core/pipelines/create/template_features.yml +++ b/nf_core/pipelines/create/template_features.yml @@ -1,499 +1,583 @@ -github: - skippable_paths: - - ".github" - - ".gitattributes" - short_description: "Use a GitHub repository." - description: "Create a GitHub repository for the pipeline." - help_text: | - This will create a GitHub repository for the pipeline. - - The repository will include: - - Continuous Integration (CI) tests - - Issues and pull requests templates - - The initialisation of a git repository is required to use the nf-core/tools. - This means that even if you unselect this option, your pipeline will still contain a `.git` directory and `.gitignore` file. - linting: - files_exist: - - ".github/ISSUE_TEMPLATE/bug_report.yml" - - ".github/ISSUE_TEMPLATE/feature_request.yml" - - ".github/PULL_REQUEST_TEMPLATE.md" - - ".github/CONTRIBUTING.md" - - ".github/.dockstore.yml" - files_unchanged: - - ".github/ISSUE_TEMPLATE/bug_report.yml" - - ".github/ISSUE_TEMPLATE/config.yml" - - ".github/ISSUE_TEMPLATE/feature_request.yml" - - ".github/PULL_REQUEST_TEMPLATE.md" - - ".github/workflows/branch.yml" - - ".github/workflows/linting_comment.yml" - - ".github/workflows/linting.yml" - - ".github/CONTRIBUTING.md" - - ".github/.dockstore.yml" - readme: - - "nextflow_badge" - nfcore_pipelines: False - custom_pipelines: True -ci: - skippable_paths: - - ".github/workflows/" - short_description: "Add Github CI tests" - description: "The pipeline will include several GitHub actions for Continuous Integration (CI) testing" - help_text: | - Nf-core provides a set of Continuous Integration (CI) tests for Github. - When you open a pull request (PR) on your pipeline repository, these tests will run automatically. - - There are different types of tests: - * Linting tests check that your code is formatted correctly and that it adheres to nf-core standards - For code linting they will use [prettier](https://prettier.io/). - * Pipeline tests run your pipeline on a small dataset to check that it works - These tests are run with a small test dataset on GitHub and a larger test dataset on AWS - * Marking old issues as stale - linting: - files_exist: - - ".github/workflows/branch.yml" - - ".github/workflows/nf-test.yml" - - ".github/actions/get-shards/action.yml" - - ".github/actions/nf-test/action.yml" - - ".github/workflows/linting_comment.yml" - - ".github/workflows/linting.yml" - nfcore_pipelines: False - custom_pipelines: True -igenomes: - skippable_paths: - - "conf/igenomes.config" - - "conf/igenomes_ignored.config" - short_description: "Use reference genomes" - description: "The pipeline will be configured to use a copy of the most common reference genome files from iGenomes" - help_text: | - Nf-core pipelines are configured to use a copy of the most common reference genome files. - - By selecting this option, your pipeline will include a configuration file specifying the paths to these files. - - The required code to use these files will also be included in the template. - When the pipeline user provides an appropriate genome key, - the pipeline will automatically download the required reference files. - - For more information about reference genomes in nf-core pipelines, - see the [nf-core docs](https://nf-co.re/docs/usage/reference_genomes). - linting: - files_exist: - - "conf/igenomes.config" - - "conf/igenomes_ignored.config" - nfcore_pipelines: True - custom_pipelines: True -github_badges: - skippable_paths: False - short_description: "Add Github badges" - description: "The README.md file of the pipeline will include GitHub badges" - help_text: | - The pipeline `README.md` will include badges for: - * AWS CI Tests - * Zenodo DOI - * Nextflow - * nf-core template version - * Conda - * Docker - * Singularity - * Launching on Nextflow Tower - linting: - readme: - - "nextflow_badge" - - "nfcore_template_badge" - nfcore_pipelines: False - custom_pipelines: True -nf_core_configs: - skippable_paths: False - short_description: "Add configuration files" - description: "The pipeline will include configuration profiles containing custom parameters required to run nf-core pipelines at different institutions" - help_text: | - Nf-core has a repository with a collection of configuration profiles. - - Those config files define a set of parameters which are specific to compute environments at different Institutions. - They can be used within all nf-core pipelines. - If you are likely to be running nf-core pipelines regularly it is a good idea to use or create a custom config file for your organisation. - - For more information about nf-core configuration profiles, see the [nf-core/configs repository](https://github.com/nf-core/configs) - linting: - files_exist: - - "conf/igenomes.config" - nextflow_config: - - "process.cpus" - - "process.memory" - - "process.time" - - "custom_config" - - "params.custom_config_version" - - "params.custom_config_base" - included_configs: False - nfcore_pipelines: False - custom_pipelines: True -is_nfcore: - skippable_paths: - - ".github/ISSUE_TEMPLATE/config" - - "CODE_OF_CONDUCT.md" - - ".github/workflows/awsfulltest.yml" - - ".github/workflows/awstest.yml" - - ".github/workflows/release-announcements.yml" - short_description: "A custom pipeline which won't be part of the nf-core organisation but be compatible with nf-core/tools." - description: "" - help_text: "" - linting: - files_exist: - - "CODE_OF_CONDUCT.md" - - "assets/nf-core-{{short_name}}_logo_light.png" - - "docs/images/nf-core-{{short_name}}_logo_light.png" - - "docs/images/nf-core-{{short_name}}_logo_dark.png" - - ".github/ISSUE_TEMPLATE/config.yml" - - ".github/workflows/awstest.yml" - - ".github/workflows/awsfulltest.yml" - files_unchanged: - - "CODE_OF_CONDUCT.md" - - "assets/nf-core-{{short_name}}_logo_light.png" - - "docs/images/nf-core-{{short_name}}_logo_light.png" - - "docs/images/nf-core-{{short_name}}_logo_dark.png" - - ".github/ISSUE_TEMPLATE/bug_report.yml" - - ".github/CONTRIBUTING.md" - - ".github/PULL_REQUEST_TEMPLATE.md" - - "assets/email_template.txt" - - "docs/README.md" - nextflow_config: - - "manifest.name" - - "manifest.homePage" - - "validation.help.beforeText" - - "validation.help.afterText" - - "validation.summary.beforeText" - - "validation.summary.afterText" - multiqc_config: - - "report_comment" - nfcore_pipelines: False - custom_pipelines: False -code_linters: - skippable_paths: - - ".pre-commit-config.yaml" - - ".prettierignore" - - ".prettierrc.yml" - - ".github/workflows/fix-linting.yml" - short_description: "Use code linters" - description: "The pipeline will include code linters and CI tests to lint your code: pre-commit, editor-config and prettier." - help_text: | - Pipelines include code linters to check the formatting of your code in order to harmonize code styles between developers. - Linters will check all non-ignored files, e.g., JSON, YAML, Nextlow or Python files in your repository. - The available code linters are: - - - pre-commit (https://pre-commit.com/): used to run all code-linters on every PR and on ever commit if you run `pre-commit install` to install it in your local repository. - - prettier (https://github.com/prettier/prettier): enforces a consistent style (indentation, quoting, line length, etc). - linting: - files_exist: - - ".prettierignore" - - ".prettierrc.yml" - nfcore_pipelines: False - custom_pipelines: True -citations: - skippable_paths: - - "assets/methods_description_template.yml" - - "CITATIONS.md" - short_description: "Include citations" - description: "Include pipeline tools citations in CITATIONS.md and a method description in the MultiQC report (if enabled)." - help_text: | - If adding citations, the pipeline template will contain a `CITATIONS.md` file to add the citations of all tools used in the pipeline. - - Additionally, it will include a YAML file (`assets/methods_description_template.yml`) to add a Materials & Methods section describing the tools used in the pieline, - and the logics to add this section to the output MultiQC report (if the report is generated). - linting: - files_exist: - - "CITATIONS.md" - nfcore_pipelines: False - custom_pipelines: True -gitpod: - skippable_paths: - - ".gitpod.yml" - short_description: "Include a gitpod environment" - description: "Include the configuration required to use Gitpod." - help_text: | - Gitpod (https://www.gitpod.io/) provides standardized and automated development environments. - - Including this to your pipeline will provide an environment with the latest version of nf-core/tools installed and all its requirements. - This is useful to have all the tools ready for pipeline development. - nfcore_pipelines: False - custom_pipelines: True -codespaces: - skippable_paths: - - ".devcontainer/devcontainer.json" - short_description: "Include GitHub Codespaces" - description: "The pipeline will include a devcontainer configuration for GitHub Codespaces, providing a development environment with nf-core/tools and Nextflow installed." - help_text: | - The pipeline will include a devcontainer configuration. - The devcontainer will create a GitHub Codespaces for Nextflow development with nf-core/tools and Nextflow installed. - - Github Codespaces (https://github.com/features/codespaces) is an online developer environment that runs in your browser, complete with VSCode and a terminal. - linting: - files_unchanged: - - ".github/CONTRIBUTING.md" - nfcore_pipelines: False - custom_pipelines: True -multiqc: - skippable_paths: - - "assets/multiqc_config.yml" - - "assets/methods_description_template.yml" - - "modules/nf-core/multiqc/" - short_description: "Use multiqc" - description: "The pipeline will include the MultiQC module which generates an HTML report for quality control." - help_text: | - MultiQC is a visualization tool that generates a single HTML report summarising all samples in your project. Most of the pipeline quality control results can be visualised in the report and further statistics are available in the report data directory. - - The pipeline will include the MultiQC module and will have special steps which also allow the software versions to be reported in the MultiQC output for future traceability. For more information about how to use MultiQC reports, see http://multiqc.info. - linting: - files_unchanged: - - ".github/CONTRIBUTING.md" - - "assets/sendmail_template.txt" - files_exist: - - "assets/multiqc_config.yml" - multiqc_config: False - nfcore_pipelines: True - custom_pipelines: True -fastqc: - skippable_paths: - - "modules/nf-core/fastqc/" - short_description: "Use fastqc" - description: "The pipeline will include the FastQC module which performs quality control analysis of input FASTQ files." - help_text: | - FastQC is a tool which provides quality control checks on raw sequencing data. - The pipeline will include the FastQC module. - nfcore_pipelines: True - custom_pipelines: True -modules: - skippable_paths: - - "conf/base.config" - - "conf/modules.config" - - "modules.json" - - "modules" - - "subworkflows" - short_description: "Use nf-core components" - description: "Include all required files to use nf-core modules and subworkflows" - help_text: | - It is *recommended* to use this feature if you want to use modules and subworkflows in your pipeline. - This will add all required files to use nf-core components or any compatible components from private repos by using `nf-core modules` and `nf-core subworkflows` commands. - linting: - nfcore_components: False - modules_json: False - base_config: False - modules_config: False - files_exist: - - "conf/base.config" - - "conf/modules.config" - - "modules.json" - nfcore_pipelines: False - custom_pipelines: True -changelog: - skippable_paths: - - "CHANGELOG.md" - short_description: "Add a changelog" - description: "Add a CHANGELOG.md file." - help_text: | - Having a `CHANGELOG.md` file in the pipeline root directory is useful to track the changes added to each version. - - You can read more information on the recommended format here: https://keepachangelog.com/en/1.0.0/ - linting: - files_exist: - - "CHANGELOG.md" - nfcore_pipelines: False - custom_pipelines: True -nf_schema: - skippable_paths: - - "subworkflows/nf-core/utils_nfschema_plugin" - - "nextflow_schema.json" - - "assets/schema_input.json" - - "assets/samplesheet.csv" - short_description: "Use nf-schema" - description: "Use the nf-schema Nextflow plugin for this pipeline." - help_text: | - [nf-schema](https://nextflow-io.github.io/nf-schema/latest/) is used to validate input parameters based on a JSON schema. - It also provides helper functionality to create help messages, get a summary - of changed parameters and validate and convert a samplesheet to a channel. - linting: - files_exist: - - "nextflow_schema.json" - schema_params: False - schema_lint: False - schema_description: False - nextflow_config: False - nfcore_pipelines: True - custom_pipelines: True -license: - skippable_paths: - - "LICENSE" - short_description: "Add a license File" - description: "Add the MIT license file." - help_text: | - To protect the copyright of the pipeline, you can add a LICENSE file. - This option ads the MIT License. You can read the conditions here: https://opensource.org/license/MIT - linting: - files_exist: - - "LICENSE" - files_unchanged: - - "LICENSE" - nfcore_pipelines: False - custom_pipelines: True -email: - skippable_paths: - - "assets/email_template.html" - - "assets/sendmail_template.txt" - - "assets/email_template.txt" - short_description: "Enable email updates" - description: "Enable sending emails on pipeline completion." - help_text: | - Enable the option of sending an email which will include pipeline execution reports on pipeline completion. - linting: - files_exist: - - "assets/email_template.html" - - "assets/sendmail_template.txt" - - "assets/email_template.txt" - files_unchanged: - - ".prettierignore" - nfcore_pipelines: False - custom_pipelines: True -adaptivecard: - skippable_paths: - - "assets/adaptivecard.json" - short_description: "Support Microsoft Teams notifications" - description: "Enable pipeline status update messages through Microsoft Teams" - help_text: | - This adds an Adaptive Card. A snippets of user interface. - This Adaptive Card is used as a template for pipeline update messages and it is compatible with Microsoft Teams. - linting: - files_unchanged: - - ".prettierignore" - nfcore_pipelines: False - custom_pipelines: True -slackreport: - skippable_paths: - - "assets/slackreport.json" - short_description: "Support Slack notifications" - description: "Enable pipeline status update messages through Slack" - help_text: | - This adds an JSON template used as a template for pipeline update messages in Slack. - linting: - files_unchanged: - - ".prettierignore" - nfcore_pipelines: False - custom_pipelines: True -documentation: - skippable_paths: - - "docs" - short_description: "Add documentation" - description: "Add documentation to the pipeline" - help_text: | - This will add documentation markdown files where you can describe your pipeline. - It includes: - - docs/README.md: A README file where you can describe the structure of your documentation. - - docs/output.md: A file where you can explain the output generated by the pipeline - - docs/usage.md: A file where you can explain the usage of the pipeline and its parameters. - - These files come with an exemplary documentation structure written. - linting: - files_exist: - - "docs/output.md" - - "docs/README.md" - - "docs/usage.md" - nfcore_pipelines: False - custom_pipelines: True -test_config: - skippable_paths: - - "conf/test.config" - - "conf/test_full.config" - - ".github/workflows/awsfulltest.yml" - - ".github/workflows/awstest.yml" - - ".github/workflows/nf-test.yml" - - ".github/actions/get-shards/action.yml" - - ".github/actions/nf-test/action.yml" - short_description: "Add testing profiles" - description: "Add two default testing profiles" - help_text: | - This will add two default testing profiles to run the pipeline with different inputs. - You can customise them and add other test profiles. - - These profiles can be used to run the pipeline with a minimal testing dataset with `nextflow run -profile test`. - - The pipeline will include two profiles: `test` and `test_full`. - In nf-core, we typically use the `test` profile to run the pipeline with a minimal dataset and the `test_full` to run the pipeline with a larger dataset that simulates a real-world scenario. - linting: - files_exist: - - "conf/test.config" - - "conf/test_full.config" - - ".github/workflows/nf-test.yml" - - ".github/actions/get-shards/action.yml" - - ".github/actions/nf-test/action.yml" - nextflow_config: False - files_unchanged: - - ".github/CONTRIBUTING.md" - - ".github/PULL_REQUEST_TEMPLATE.md" - nfcore_pipelines: False - custom_pipelines: True -nf-test: - skippable_paths: - - ".github/workflows/nf-test.yml" - - ".github/actions/get-shards/action.yml" - - ".github/actions/nf-test/action.yml" - - "nf-test.config" - - "tests/default.nf.test" - - "tests/.nftignore" - - "tests/nextflow.config" - short_description: "Add pipeline testing" - description: "Add pipeline testing using nf-test" - help_text: | - This will add pipeline testing with [nf-test](https://www.nf-test.com/). - - Will add and `nf-test.config` file setting up the appropriate configuration to test your pipeline. - On top of that, it will also add the Continuous Integration (CI) GitHub actions to run these tests. - - If you skip this feature, you will still be able to test your pipeline with a `test` profile by running the pipeline. - But you won't have the automated CI testing. - You can add CI by yourself. - linting: - files_exist: - - ".github/workflows/nf-test.yml" - - ".github/actions/get-shards/action.yml" - - ".github/actions/nf-test/action.yml" - - "nf-test.config" - - "tests/default.nf.test" - nf_test_content: False - nfcore_pipelines: False - custom_pipelines: True -seqera_platform: - skippable_paths: - - "tower.yml" - short_description: "Add Seqera Platform output" - description: "Add a YAML file to specify which output files to upload when launching a pipeline from the Seqera Platform" - help_text: | - When launching a pipeline with the Seqera Platform, a `tower.yml` file can be used to add configuration options. - - In the pipeline template, this file is used to specify the output files of you pipeline which will be shown on the reports tab of Seqera Platform. - You can extend this file adding any other desired configuration. - nfcore_pipelines: False - custom_pipelines: True -rocrate: - skippable_paths: - - "ro-crate-metadata.json" - short_description: "Add RO-Crate metadata" - description: "Add a RO-Crate metadata file to describe the pipeline" - help_text: | - RO-Crate is a metadata specification to describe research data and software. - This will add a `ro-crate-metadata.json` file to describe the pipeline. - nfcore_pipelines: False - custom_pipelines: True - linting: - files_warn: - - "ro-crate-metadata.json" - files_unchanged: - - ".prettierignore" -vscode: - skippable_paths: - - ".vscode" - short_description: "Render website admonitions in VSCode" - description: "Add a VSCode configuration to render website admonitions" - help_text: | - This will add a VSCode configuration file to render the admonitions in markdown files with the same style as the nf-core website. - - Adds the `.vscode` directory to the pipelinerepository. - nfcore_pipelines: False - custom_pipelines: True +repository_setup: + name: "Repository Setup" + features: + github: + skippable_paths: + - ".github" + - ".gitattributes" + short_description: "Use a GitHub repository." + description: "Create a GitHub repository for the pipeline." + help_text: | + This will create a GitHub repository for the pipeline. + + The repository will include: + - Continuous Integration (CI) tests + - Issues and pull requests templates + + The initialisation of a git repository is required to use the nf-core/tools. + This means that even if you unselect this option, your pipeline will still contain a `.git` directory and `.gitignore` file. + linting: + files_exist: + - ".github/ISSUE_TEMPLATE/bug_report.yml" + - ".github/ISSUE_TEMPLATE/feature_request.yml" + - ".github/PULL_REQUEST_TEMPLATE.md" + - ".github/CONTRIBUTING.md" + - ".github/.dockstore.yml" + files_unchanged: + - ".github/ISSUE_TEMPLATE/bug_report.yml" + - ".github/ISSUE_TEMPLATE/config.yml" + - ".github/ISSUE_TEMPLATE/feature_request.yml" + - ".github/PULL_REQUEST_TEMPLATE.md" + - ".github/workflows/branch.yml" + - ".github/workflows/linting_comment.yml" + - ".github/workflows/linting.yml" + - ".github/CONTRIBUTING.md" + - ".github/.dockstore.yml" + readme: + - "nextflow_badge" + nfcore_pipelines: False + custom_pipelines: True + default: True + + github_badges: + skippable_paths: False + short_description: "Add Github badges" + description: "The README.md file of the pipeline will include GitHub badges" + help_text: | + The pipeline `README.md` will include badges for: + * AWS CI Tests + * Zenodo DOI + * Nextflow + * nf-core template version + * Conda + * Docker + * Singularity + * Launching on Nextflow Tower + linting: + readme: + - "nextflow_badge" + - "nfcore_template_badge" + nfcore_pipelines: False + custom_pipelines: True + default: True + + changelog: + skippable_paths: + - "CHANGELOG.md" + short_description: "Add a changelog" + description: "Add a CHANGELOG.md file." + help_text: | + Having a `CHANGELOG.md` file in the pipeline root directory is useful to track the changes added to each version. + + You can read more information on the recommended format here: https://keepachangelog.com/en/1.0.0/ + linting: + files_exist: + - "CHANGELOG.md" + nfcore_pipelines: False + custom_pipelines: True + default: true + + license: + skippable_paths: + - "LICENSE" + short_description: "Add a license File" + description: "Add the MIT license file." + help_text: | + To protect the copyright of the pipeline, you can add a LICENSE file. + This option ads the MIT License. You can read the conditions here: https://opensource.org/license/MIT + linting: + files_exist: + - "LICENSE" + files_unchanged: + - "LICENSE" + nfcore_pipelines: False + custom_pipelines: True + default: true + +continuous_integration_testing: + name: "Continuous Integration & Testing" + features: + ci: + skippable_paths: + - ".github/workflows/" + short_description: "Add Github CI tests" + description: "The pipeline will include several GitHub actions for Continuous Integration (CI) testing" + help_text: | + Nf-core provides a set of Continuous Integration (CI) tests for Github. + When you open a pull request (PR) on your pipeline repository, these tests will run automatically. + + There are different types of tests: + * Linting tests check that your code is formatted correctly and that it adheres to nf-core standards + For code linting they will use [prettier](https://prettier.io/). + * Pipeline tests run your pipeline on a small dataset to check that it works + These tests are run with a small test dataset on GitHub and a larger test dataset on AWS + * Marking old issues as stale + linting: + files_exist: + - ".github/workflows/branch.yml" + - ".github/workflows/nf-test.yml" + - ".github/actions/get-shards/action.yml" + - ".github/actions/nf-test/action.yml" + - ".github/workflows/linting_comment.yml" + - ".github/workflows/linting.yml" + nfcore_pipelines: False + custom_pipelines: True + default: true + + test_config: + skippable_paths: + - "conf/test.config" + - "conf/test_full.config" + - ".github/workflows/awsfulltest.yml" + - ".github/workflows/awstest.yml" + - ".github/workflows/nf-test.yml" + - ".github/actions/get-shards/action.yml" + - ".github/actions/nf-test/action.yml" + short_description: "Add testing profiles" + description: "Add two default testing profiles" + help_text: | + This will add two default testing profiles to run the pipeline with different inputs. + You can customise them and add other test profiles. + + These profiles can be used to run the pipeline with a minimal testing dataset with `nextflow run -profile test`. + + The pipeline will include two profiles: `test` and `test_full`. + In nf-core, we typically use the `test` profile to run the pipeline with a minimal dataset and the `test_full` to run the pipeline with a larger dataset that simulates a real-world scenario. + linting: + files_exist: + - "conf/test.config" + - "conf/test_full.config" + - ".github/workflows/nf-test.yml" + - ".github/actions/get-shards/action.yml" + - ".github/actions/nf-test/action.yml" + nextflow_config: False + files_unchanged: + - ".github/CONTRIBUTING.md" + - ".github/PULL_REQUEST_TEMPLATE.md" + nfcore_pipelines: False + custom_pipelines: True + default: true + + nf-test: + skippable_paths: + - ".github/workflows/nf-test.yml" + - ".github/actions/get-shards/action.yml" + - ".github/actions/nf-test/action.yml" + - "nf-test.config" + - "tests/default.nf.test" + - "tests/.nftignore" + - "tests/nextflow.config" + short_description: "Add pipeline testing" + description: "Add pipeline testing using nf-test" + help_text: | + This will add pipeline testing with [nf-test](https://www.nf-test.com/). + + Will add and `nf-test.config` file setting up the appropriate configuration to test your pipeline. + On top of that, it will also add the Continuous Integration (CI) GitHub actions to run these tests. + + If you skip this feature, you will still be able to test your pipeline with a `test` profile by running the pipeline. + But you won't have the automated CI testing. + You can add CI by yourself. + linting: + files_exist: + - ".github/workflows/nf-test.yml" + - ".github/actions/get-shards/action.yml" + - ".github/actions/nf-test/action.yml" + - "nf-test.config" + - "tests/default.nf.test" + nf_test_content: False + nfcore_pipelines: False + custom_pipelines: True + default: true + +components_modules: + name: "Components & Modules" + features: + igenomes: + skippable_paths: + - "conf/igenomes.config" + - "conf/igenomes_ignored.config" + short_description: "Use reference genomes" + description: "The pipeline will be configured to use a copy of the most common reference genome files from iGenomes" + help_text: | + Nf-core pipelines are configured to use a copy of the most common reference genome files. + + By selecting this option, your pipeline will include a configuration file specifying the paths to these files. + + The required code to use these files will also be included in the template. + When the pipeline user provides an appropriate genome key, + the pipeline will automatically download the required reference files. + + For more information about reference genomes in nf-core pipelines, + see the [nf-core docs](https://nf-co.re/docs/usage/reference_genomes). + linting: + files_exist: + - "conf/igenomes.config" + - "conf/igenomes_ignored.config" + nfcore_pipelines: True + custom_pipelines: True + default: true + + modules: + skippable_paths: + - "conf/base.config" + - "conf/modules.config" + - "modules.json" + - "modules" + - "subworkflows" + short_description: "Use nf-core components" + description: "Include all required files to use nf-core modules and subworkflows" + help_text: | + It is *recommended* to use this feature if you want to use modules and subworkflows in your pipeline. + This will add all required files to use nf-core components or any compatible components from private repos by using `nf-core modules` and `nf-core subworkflows` commands. + linting: + nfcore_components: False + modules_json: False + base_config: False + modules_config: False + files_exist: + - "conf/base.config" + - "conf/modules.config" + - "modules.json" + nfcore_pipelines: False + custom_pipelines: True + default: true + + multiqc: + skippable_paths: + - "assets/multiqc_config.yml" + - "assets/methods_description_template.yml" + - "modules/nf-core/multiqc/" + short_description: "Use multiqc" + description: "The pipeline will include the MultiQC module which generates an HTML report for quality control." + help_text: | + MultiQC is a visualization tool that generates a single HTML report summarising all samples in your project. Most of the pipeline quality control results can be visualised in the report and further statistics are available in the report data directory. + + The pipeline will include the MultiQC module and will have special steps which also allow the software versions to be reported in the MultiQC output for future traceability. For more information about how to use MultiQC reports, see http://multiqc.info. + linting: + files_unchanged: + - ".github/CONTRIBUTING.md" + - "assets/sendmail_template.txt" + files_exist: + - "assets/multiqc_config.yml" + multiqc_config: False + nfcore_pipelines: True + custom_pipelines: True + default: true + + fastqc: + skippable_paths: + - "modules/nf-core/fastqc/" + short_description: "Use fastqc" + description: "The pipeline will include the FastQC module which performs quality control analysis of input FASTQ files." + help_text: | + FastQC is a tool which provides quality control checks on raw sequencing data. + The pipeline will include the FastQC module. + nfcore_pipelines: True + custom_pipelines: True + default: true + + nf_schema: + skippable_paths: + - "subworkflows/nf-core/utils_nfschema_plugin" + - "nextflow_schema.json" + - "assets/schema_input.json" + - "assets/samplesheet.csv" + short_description: "Use nf-schema" + description: "Use the nf-schema Nextflow plugin for this pipeline." + help_text: | + [nf-schema](https://nextflow-io.github.io/nf-schema/latest/) is used to validate input parameters based on a JSON schema. + It also provides helper functionality to create help messages, get a summary + of changed parameters and validate and convert a samplesheet to a channel. + linting: + files_exist: + - "nextflow_schema.json" + schema_params: False + schema_lint: False + schema_description: False + nextflow_config: False + nfcore_pipelines: True + custom_pipelines: True + default: true + +configurations: + name: "Configurations" + features: + nf_core_configs: + skippable_paths: False + short_description: "Add configuration files" + description: "The pipeline will include configuration profiles containing custom parameters required to run nf-core pipelines at different institutions" + help_text: | + Nf-core has a repository with a collection of configuration profiles. + + Those config files define a set of parameters which are specific to compute environments at different Institutions. + They can be used within all nf-core pipelines. + If you are likely to be running nf-core pipelines regularly it is a good idea to use or create a custom config file for your organisation. + + For more information about nf-core configuration profiles, see the [nf-core/configs repository](https://github.com/nf-core/configs) + linting: + files_exist: + - "conf/igenomes.config" + nextflow_config: + - "process.cpus" + - "process.memory" + - "process.time" + - "custom_config" + - "params.custom_config_version" + - "params.custom_config_base" + included_configs: False + nfcore_pipelines: False + custom_pipelines: True + default: true + + is_nfcore: + skippable_paths: + - ".github/ISSUE_TEMPLATE/config" + - "CODE_OF_CONDUCT.md" + - ".github/workflows/awsfulltest.yml" + - ".github/workflows/awstest.yml" + - ".github/workflows/release-announcements.yml" + short_description: "A custom pipeline which won't be part of the nf-core organisation but be compatible with nf-core/tools." + description: "" + help_text: "" + linting: + files_exist: + - "CODE_OF_CONDUCT.md" + - "assets/nf-core-{{short_name}}_logo_light.png" + - "docs/images/nf-core-{{short_name}}_logo_light.png" + - "docs/images/nf-core-{{short_name}}_logo_dark.png" + - ".github/ISSUE_TEMPLATE/config.yml" + - ".github/workflows/awstest.yml" + - ".github/workflows/awsfulltest.yml" + files_unchanged: + - "CODE_OF_CONDUCT.md" + - "assets/nf-core-{{short_name}}_logo_light.png" + - "docs/images/nf-core-{{short_name}}_logo_light.png" + - "docs/images/nf-core-{{short_name}}_logo_dark.png" + - ".github/ISSUE_TEMPLATE/bug_report.yml" + - ".github/CONTRIBUTING.md" + - ".github/PULL_REQUEST_TEMPLATE.md" + - "assets/email_template.txt" + - "docs/README.md" + nextflow_config: + - "manifest.name" + - "manifest.homePage" + - "validation.help.beforeText" + - "validation.help.afterText" + - "validation.summary.beforeText" + - "validation.summary.afterText" + multiqc_config: + - "report_comment" + nfcore_pipelines: False + custom_pipelines: False + default: true + + seqera_platform: + skippable_paths: + - "tower.yml" + short_description: "Add Seqera Platform output" + description: "Add a YAML file to specify which output files to upload when launching a pipeline from the Seqera Platform" + help_text: | + When launching a pipeline with the Seqera Platform, a `tower.yml` file can be used to add configuration options. + + In the pipeline template, this file is used to specify the output files of you pipeline which will be shown on the reports tab of Seqera Platform. + You can extend this file adding any other desired configuration. + nfcore_pipelines: False + custom_pipelines: True + default: true + + gpu: + skippable_paths: False + short_description: "Use GPU" + description: "Add GPU support to the pipeline" + help_text: | + This will add GPU support to the pipeline. It will add a `use_gpu` parameter to the pipeline. + The pipeline will be able to run on GPU-enabled compute environments. + nfcore_pipelines: True + custom_pipelines: True + default: False + +development_environments: + name: "Development Environments" + features: + gitpod: + skippable_paths: + - ".gitpod.yml" + short_description: "Include a gitpod environment" + description: "Include the configuration required to use Gitpod." + help_text: | + Gitpod (https://www.gitpod.io/) provides standardized and automated development environments. + + Including this to your pipeline will provide an environment with the latest version of nf-core/tools installed and all its requirements. + This is useful to have all the tools ready for pipeline development. + nfcore_pipelines: False + custom_pipelines: True + default: true + + codespaces: + skippable_paths: + - ".devcontainer/devcontainer.json" + short_description: "Include GitHub Codespaces" + description: "The pipeline will include a devcontainer configuration for GitHub Codespaces, providing a development environment with nf-core/tools and Nextflow installed." + help_text: | + The pipeline will include a devcontainer configuration. + The devcontainer will create a GitHub Codespaces for Nextflow development with nf-core/tools and Nextflow installed. + + Github Codespaces (https://github.com/features/codespaces) is an online developer environment that runs in your browser, complete with VSCode and a terminal. + linting: + files_unchanged: + - ".github/CONTRIBUTING.md" + nfcore_pipelines: False + custom_pipelines: True + default: true + + vscode: + skippable_paths: + - ".vscode" + short_description: "Render website admonitions in VSCode" + description: "Add a VSCode configuration to render website admonitions" + help_text: | + This will add a VSCode configuration file to render the admonitions in markdown files with the same style as the nf-core website. + + Adds the `.vscode` directory to the pipelinerepository. + nfcore_pipelines: False + custom_pipelines: True + default: true + +code_quality: + name: "Code Quality" + features: + code_linters: + skippable_paths: + - ".pre-commit-config.yaml" + - ".prettierignore" + - ".prettierrc.yml" + - ".github/workflows/fix-linting.yml" + short_description: "Use code linters" + description: "The pipeline will include code linters and CI tests to lint your code: pre-commit, editor-config and prettier." + help_text: | + Pipelines include code linters to check the formatting of your code in order to harmonize code styles between developers. + Linters will check all non-ignored files, e.g., JSON, YAML, Nextlow or Python files in your repository. + The available code linters are: + + - pre-commit (https://pre-commit.com/): used to run all code-linters on every PR and on ever commit if you run `pre-commit install` to install it in your local repository. + - prettier (https://github.com/prettier/prettier): enforces a consistent style (indentation, quoting, line length, etc). + linting: + files_exist: + - ".prettierignore" + - ".prettierrc.yml" + nfcore_pipelines: False + custom_pipelines: True + default: true + +documentation_metadata: + name: "Documentation & metadata" + features: + citations: + skippable_paths: + - "assets/methods_description_template.yml" + - "CITATIONS.md" + short_description: "Include citations" + description: "Include pipeline tools citations in CITATIONS.md and a method description in the MultiQC report (if enabled)." + help_text: | + If adding citations, the pipeline template will contain a `CITATIONS.md` file to add the citations of all tools used in the pipeline. + + Additionally, it will include a YAML file (`assets/methods_description_template.yml`) to add a Materials & Methods section describing the tools used in the pieline, + and the logics to add this section to the output MultiQC report (if the report is generated). + linting: + files_exist: + - "CITATIONS.md" + nfcore_pipelines: False + custom_pipelines: True + default: true + + documentation: + skippable_paths: + - "docs" + short_description: "Add documentation" + description: "Add documentation to the pipeline" + help_text: | + This will add documentation markdown files where you can describe your pipeline. + It includes: + - docs/README.md: A README file where you can describe the structure of your documentation. + - docs/output.md: A file where you can explain the output generated by the pipeline + - docs/usage.md: A file where you can explain the usage of the pipeline and its parameters. + + These files come with an exemplary documentation structure written. + linting: + files_exist: + - "docs/output.md" + - "docs/README.md" + - "docs/usage.md" + nfcore_pipelines: False + custom_pipelines: True + default: true + + rocrate: + skippable_paths: + - "ro-crate-metadata.json" + short_description: "Add RO-Crate metadata" + description: "Add a RO-Crate metadata file to describe the pipeline" + help_text: | + RO-Crate is a metadata specification to describe research data and software. + This will add a `ro-crate-metadata.json` file to describe the pipeline. + nfcore_pipelines: False + custom_pipelines: True + linting: + files_warn: + - "ro-crate-metadata.json" + files_unchanged: + - ".prettierignore" + default: true + +notifications: + name: "Notifications" + features: + email: + skippable_paths: + - "assets/email_template.html" + - "assets/sendmail_template.txt" + - "assets/email_template.txt" + short_description: "Enable email updates" + description: "Enable sending emails on pipeline completion." + help_text: | + Enable the option of sending an email which will include pipeline execution reports on pipeline completion. + linting: + files_exist: + - "assets/email_template.html" + - "assets/sendmail_template.txt" + - "assets/email_template.txt" + files_unchanged: + - ".prettierignore" + nfcore_pipelines: False + custom_pipelines: True + default: true + + adaptivecard: + skippable_paths: + - "assets/adaptivecard.json" + short_description: "Support Microsoft Teams notifications" + description: "Enable pipeline status update messages through Microsoft Teams" + help_text: | + This adds an Adaptive Card. A snippets of user interface. + This Adaptive Card is used as a template for pipeline update messages and it is compatible with Microsoft Teams. + linting: + files_unchanged: + - ".prettierignore" + nfcore_pipelines: False + custom_pipelines: True + default: true + + slackreport: + skippable_paths: + - "assets/slackreport.json" + short_description: "Support Slack notifications" + description: "Enable pipeline status update messages through Slack" + help_text: | + This adds an JSON template used as a template for pipeline update messages in Slack. + linting: + files_unchanged: + - ".prettierignore" + nfcore_pipelines: False + custom_pipelines: True + default: true diff --git a/nf_core/pipelines/create/utils.py b/nf_core/pipelines/create/utils.py index 40d6452c1e..cda670c6e7 100644 --- a/nf_core/pipelines/create/utils.py +++ b/nf_core/pipelines/create/utils.py @@ -177,12 +177,13 @@ def hide(self) -> None: class PipelineFeature(Static): """Widget for the selection of pipeline features.""" - def __init__(self, markdown: str, title: str, subtitle: str, field_id: str, **kwargs) -> None: + def __init__(self, markdown: str, title: str, subtitle: str, field_id: str, default: bool, **kwargs) -> None: super().__init__(**kwargs) self.markdown = markdown self.title = title self.subtitle = subtitle self.field_id = field_id + self.default = default def on_button_pressed(self, event: Button.Pressed) -> None: """When the button is pressed, change the type of the button.""" @@ -199,7 +200,7 @@ def compose(self) -> ComposeResult: Hidden row with a help text box. """ yield HorizontalScroll( - Switch(value=True, id=self.field_id), + Switch(value=self.default, id=self.field_id), Static(self.title, classes="feature_title"), Static(self.subtitle, classes="feature_subtitle"), Button("Show help", id="show_help", variant="primary"), diff --git a/nf_core/pipelines/lint/nf_test_content.py b/nf_core/pipelines/lint/nf_test_content.py index edea8c8b5f..70f5bc1a21 100644 --- a/nf_core/pipelines/lint/nf_test_content.py +++ b/nf_core/pipelines/lint/nf_test_content.py @@ -144,25 +144,25 @@ def nf_test_content(self) -> dict[str, list[str]]: # Check if tests/nextflow.config is present if not conf_fn.exists(): failed.append(f"'{conf_fn.relative_to(self.wf_path)}' does not exist") - - if nf_test_content_conf is None or str(conf_fn.relative_to(self.wf_path)) not in nf_test_content_conf: - checks_passed = {check: False for check in config_checks} - with open(conf_fn) as fh: - for line in fh: - line = line.strip() - for check_name, config_check_info in config_checks.items(): - if re.search(str(config_check_info["pattern"]), line): - passed.append( - f"'{conf_fn.relative_to(self.wf_path)}' contains {config_check_info['description']}" - ) - checks_passed[check_name] = True - for check_name, config_check_info in config_checks.items(): - if not checks_passed[check_name]: - failed.append( - f"'{conf_fn.relative_to(self.wf_path)}' does not contain {config_check_info['description']}" - ) else: - ignored.append(f"'{conf_fn.relative_to(self.wf_path)}' checking ignored") + if nf_test_content_conf is None or str(conf_fn.relative_to(self.wf_path)) not in nf_test_content_conf: + checks_passed = {check: False for check in config_checks} + with open(conf_fn) as fh: + for line in fh: + line = line.strip() + for check_name, config_check_info in config_checks.items(): + if re.search(str(config_check_info["pattern"]), line): + passed.append( + f"'{conf_fn.relative_to(self.wf_path)}' contains {config_check_info['description']}" + ) + checks_passed[check_name] = True + for check_name, config_check_info in config_checks.items(): + if not checks_passed[check_name]: + failed.append( + f"'{conf_fn.relative_to(self.wf_path)}' does not contain {config_check_info['description']}" + ) + else: + ignored.append(f"'{conf_fn.relative_to(self.wf_path)}' checking ignored") # Content of nf-test.config file nf_test_conf_fn = Path(self.wf_path, "nf-test.config") @@ -184,21 +184,24 @@ def nf_test_content(self) -> dict[str, list[str]]: }, } - if nf_test_content_conf is None or str(nf_test_conf_fn.relative_to(self.wf_path)) not in nf_test_content_conf: - checks_passed = {check: False for check in nf_test_checks} - with open(nf_test_conf_fn) as fh: - for line in fh: - line = line.strip() - for check_name, nf_test_check_info in nf_test_checks.items(): - if re.search(str(nf_test_check_info["pattern"]), line): - passed.append( - f"'{nf_test_conf_fn.relative_to(self.wf_path)}' {nf_test_check_info['description']}" - ) - checks_passed[check_name] = True - for check_name, nf_test_check_info in nf_test_checks.items(): - if not checks_passed[check_name]: - failed.append(f"'{nf_test_conf_fn.relative_to(self.wf_path)}' {nf_test_check_info['failure_msg']}") + if not nf_test_conf_fn.exists(): + failed.append(f"'{nf_test_conf_fn.relative_to(self.wf_path)}' does not exist") else: - ignored.append(f"'{nf_test_conf_fn.relative_to(self.wf_path)}' checking ignored") + if nf_test_content_conf is None or str(nf_test_conf_fn.relative_to(self.wf_path)) not in nf_test_content_conf: + checks_passed = {check: False for check in nf_test_checks} + with open(nf_test_conf_fn) as fh: + for line in fh: + line = line.strip() + for check_name, nf_test_check_info in nf_test_checks.items(): + if re.search(str(nf_test_check_info["pattern"]), line): + passed.append( + f"'{nf_test_conf_fn.relative_to(self.wf_path)}' {nf_test_check_info['description']}" + ) + checks_passed[check_name] = True + for check_name, nf_test_check_info in nf_test_checks.items(): + if not checks_passed[check_name]: + failed.append(f"'{nf_test_conf_fn.relative_to(self.wf_path)}' {nf_test_check_info['failure_msg']}") + else: + ignored.append(f"'{nf_test_conf_fn.relative_to(self.wf_path)}' checking ignored") return {"passed": passed, "failed": failed, "ignored": ignored} diff --git a/tests/pipelines/__snapshots__/test_create_app/test_customisation_help.svg b/tests/pipelines/__snapshots__/test_create_app/test_customisation_help.svg index 5188880b1e..0adf318a71 100644 --- a/tests/pipelines/__snapshots__/test_create_app/test_customisation_help.svg +++ b/tests/pipelines/__snapshots__/test_create_app/test_customisation_help.svg @@ -39,22 +39,24 @@ .terminal-r5 { fill: #121212 } .terminal-r6 { fill: #191919 } .terminal-r7 { fill: #1e1e1e } -.terminal-r8 { fill: #6db2ff } -.terminal-r9 { fill: #808080 } -.terminal-r10 { fill: #ddedf9;font-weight: bold } -.terminal-r11 { fill: #004295 } +.terminal-r8 { fill: #0178d4;text-decoration: underline; } +.terminal-r9 { fill: #6db2ff } +.terminal-r10 { fill: #808080 } +.terminal-r11 { fill: #ddedf9;font-weight: bold } .terminal-r12 { fill: #000000 } -.terminal-r13 { fill: #0178d4 } -.terminal-r14 { fill: #2d2d2d } -.terminal-r15 { fill: #272727 } -.terminal-r16 { fill: #e0e0e0;font-weight: bold } -.terminal-r17 { fill: #0d0d0d } -.terminal-r18 { fill: #333333 } -.terminal-r19 { fill: #7ae998 } -.terminal-r20 { fill: #0a180e;font-weight: bold } -.terminal-r21 { fill: #008139 } -.terminal-r22 { fill: #ffa62b;font-weight: bold } -.terminal-r23 { fill: #495259 } +.terminal-r13 { fill: #004295 } +.terminal-r14 { fill: #0178d4 } +.terminal-r15 { fill: #2d2d2d } +.terminal-r16 { fill: #272727 } +.terminal-r17 { fill: #e0e0e0;font-weight: bold } +.terminal-r18 { fill: #0d0d0d } +.terminal-r19 { fill: #a5a5a5;font-weight: bold } +.terminal-r20 { fill: #e4e4e4;font-weight: bold } +.terminal-r21 { fill: #7ae998 } +.terminal-r22 { fill: #0a180e;font-weight: bold } +.terminal-r23 { fill: #008139 } +.terminal-r24 { fill: #ffa62b;font-weight: bold } +.terminal-r25 { fill: #495259 } @@ -218,7 +220,7 @@ - + nf-core pipelines create — Create a new pipeline with the nf-core pipeline @@ -229,47 +231,47 @@ ▔▔▔▔▔▔▔▔ Toggle all features ▁▁▁▁▁▁▁▁ -▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ -Use a GitHub repository.Create a GitHub Show help  -▁▁▁▁▁▁▁▁repository for the▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ -pipeline. + + +Repository Setup + -▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ -Add Github CI testsThe pipeline will Show help  -▁▁▁▁▁▁▁▁include several GitHub▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ -actions for Continuous▂▂ -Integration (CI) testing - -▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ -Use reference genomesThe pipeline will be Hide help  -▁▁▁▁▁▁▁▁configured to use a copy▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ -of the most common -reference genome files -from iGenomes +▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ +Use a GitHub repository.Create a GitHub Show help ▂▂ +▁▁▁▁▁▁▁▁repository for the▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ +pipeline. + +▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ +Add Github badgesThe README.md file of Hide help  +▁▁▁▁▁▁▁▁the pipeline will▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ +include GitHub badges + + +The pipeline README.md will include badges for: - -Nf-core pipelines are configured to use a copy of the most common reference -genome files. - -By selecting this option, your pipeline will include a configuration file -specifying the paths to these files. - -The required code to use these files will also be included in the template. When -the pipeline user provides an appropriate genome key, the pipeline will -automatically download the required reference files. -▅▅ -For more information about reference genomes in nf-core pipelines, see the - - -▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ -Add Github badgesThe README.md file of Show help  -▁▁▁▁▁▁▁▁the pipeline will▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ -include GitHub badges -▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ - Back  Continue  -▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ +● AWS CI Tests +● Zenodo DOI +● Nextflow +● nf-core template version +● Conda +● Docker +● Singularity +● Launching on Nextflow Tower + + + +▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ +Add a changelogAdd a CHANGELOG.md file. Show help  +▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ +▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ +Add a license FileAdd the MIT license Show help  +▁▁▁▁▁▁▁▁file.▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ + +▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ + Back  Continue  +▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ - d Toggle dark mode  q Quit  a Toggle all ^p palette + d Toggle dark mode  q Quit  a Toggle all ^p palette diff --git a/tests/pipelines/__snapshots__/test_create_app/test_type_custom.svg b/tests/pipelines/__snapshots__/test_create_app/test_type_custom.svg index 08117c8ec4..df8d2ee879 100644 --- a/tests/pipelines/__snapshots__/test_create_app/test_type_custom.svg +++ b/tests/pipelines/__snapshots__/test_create_app/test_type_custom.svg @@ -39,21 +39,22 @@ .terminal-r5 { fill: #121212 } .terminal-r6 { fill: #0178d4 } .terminal-r7 { fill: #272727 } -.terminal-r8 { fill: #191919 } -.terminal-r9 { fill: #6db2ff } -.terminal-r10 { fill: #1e1e1e } -.terminal-r11 { fill: #808080 } -.terminal-r12 { fill: #ddedf9;font-weight: bold } -.terminal-r13 { fill: #004295 } -.terminal-r14 { fill: #000000 } -.terminal-r15 { fill: #2d2d2d } -.terminal-r16 { fill: #7ae998 } -.terminal-r17 { fill: #e0e0e0;font-weight: bold } -.terminal-r18 { fill: #0a180e;font-weight: bold } -.terminal-r19 { fill: #0d0d0d } -.terminal-r20 { fill: #008139 } -.terminal-r21 { fill: #ffa62b;font-weight: bold } -.terminal-r22 { fill: #495259 } +.terminal-r8 { fill: #0178d4;text-decoration: underline; } +.terminal-r9 { fill: #191919 } +.terminal-r10 { fill: #6db2ff } +.terminal-r11 { fill: #1e1e1e } +.terminal-r12 { fill: #808080 } +.terminal-r13 { fill: #ddedf9;font-weight: bold } +.terminal-r14 { fill: #004295 } +.terminal-r15 { fill: #000000 } +.terminal-r16 { fill: #2d2d2d } +.terminal-r17 { fill: #7ae998 } +.terminal-r18 { fill: #e0e0e0;font-weight: bold } +.terminal-r19 { fill: #0a180e;font-weight: bold } +.terminal-r20 { fill: #0d0d0d } +.terminal-r21 { fill: #008139 } +.terminal-r22 { fill: #ffa62b;font-weight: bold } +.terminal-r23 { fill: #495259 } @@ -217,7 +218,7 @@ - + nf-core pipelines create — Create a new pipeline with the nf-core pipeline @@ -228,47 +229,47 @@ ▔▔▔▔▔▔▔▔ Toggle all features ▁▁▁▁▁▁▁▁ -▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ -Use a GitHub repository.Create a GitHub Show help  -▁▁▁▁▁▁▁▁repository for the▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ -pipeline. + + +Repository Setup + -▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ -Add Github CI testsThe pipeline will Show help  -▁▁▁▁▁▁▁▁include several GitHub▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ -actions for Continuous -Integration (CI) testing▃▃ - -▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ -Use reference genomesThe pipeline will be Show help  -▁▁▁▁▁▁▁▁configured to use a copy▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ -of the most common -reference genome files -from iGenomes - -▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ -Add Github badgesThe README.md file of Show help  -▁▁▁▁▁▁▁▁the pipeline will▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ -include GitHub badges +▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ +Use a GitHub repository.Create a GitHub Show help  +▁▁▁▁▁▁▁▁repository for the▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▆▆ +pipeline. + +▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ +Add Github badgesThe README.md file of Show help  +▁▁▁▁▁▁▁▁the pipeline will▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ +include GitHub badges + +▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ +Add a changelogAdd a CHANGELOG.md file. Show help  +▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ +▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ +Add a license FileAdd the MIT license Show help  +▁▁▁▁▁▁▁▁file.▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ + -▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ -Add configuration filesThe pipeline will Show help  -▁▁▁▁▁▁▁▁include configuration▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ -profiles containing -custom parameters -required to run nf-core -pipelines at different -institutions - -▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ -Use code lintersThe pipeline will Show help  -▁▁▁▁▁▁▁▁include code linters and▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ -CI tests to lint your -▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ - Back  Continue  -▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ + +Continuous Integration & Testing + + +▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ +Add Github CI testsThe pipeline will Show help  +▁▁▁▁▁▁▁▁include several GitHub▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ +actions for Continuous +Integration (CI) testing + +▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ +Add testing profilesAdd two default testing Show help  +▁▁▁▁▁▁▁▁profiles▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ +▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ + Back  Continue  +▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ - d Toggle dark mode  q Quit  a Toggle all ^p palette + d Toggle dark mode  q Quit  a Toggle all ^p palette diff --git a/tests/pipelines/__snapshots__/test_create_app/test_type_nfcore.svg b/tests/pipelines/__snapshots__/test_create_app/test_type_nfcore.svg index d7ee64e0cb..f594d2348a 100644 --- a/tests/pipelines/__snapshots__/test_create_app/test_type_nfcore.svg +++ b/tests/pipelines/__snapshots__/test_create_app/test_type_nfcore.svg @@ -214,7 +214,7 @@ - + nf-core pipelines create — Create a new pipeline with the nf-core pipeline @@ -222,40 +222,40 @@ Template features -▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ -Use reference genomesThe pipeline will be Show help  -▁▁▁▁▁▁▁▁configured to use a copy▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ -of the most common -reference genome files -from iGenomes - -▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ -Use multiqcThe pipeline will include Show help  -▁▁▁▁▁▁▁▁the MultiQC module which▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ -generates an HTML report -for quality control. - -▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ -Use fastqcThe pipeline will include Show help  -▁▁▁▁▁▁▁▁the FastQC module which▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ -performs quality control -analysis of input FASTQ -files. - -▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ -Use nf-schemaUse the nf-schema Show help  -▁▁▁▁▁▁▁▁Nextflow plugin for this▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ -pipeline. - - - +Components & Modules + + +▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ +Use reference genomesThe pipeline will be Show help  +▁▁▁▁▁▁▁▁configured to use a copy▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ +of the most common +reference genome files +from iGenomes + +▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ +Use multiqcThe pipeline will include Show help  +▁▁▁▁▁▁▁▁the MultiQC module which▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ +generates an HTML report +for quality control. + +▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ +Use fastqcThe pipeline will include Show help  +▁▁▁▁▁▁▁▁the FastQC module which▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ +performs quality control +analysis of input FASTQ +files. + +▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ +Use nf-schemaUse the nf-schema Show help  +▁▁▁▁▁▁▁▁Nextflow plugin for this▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ +pipeline. - +Configurations - - - +▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔ +Use GPUAdd GPU support to the Show help  +▁▁▁▁▁▁▁▁pipeline▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁▁ diff --git a/tests/pipelines/test_create.py b/tests/pipelines/test_create.py index b8e8cb22a2..d2ee4dd246 100644 --- a/tests/pipelines/test_create.py +++ b/tests/pipelines/test_create.py @@ -104,7 +104,9 @@ def test_pipeline_creation_initiation_customize_template(self, tmp_path): def test_pipeline_creation_with_yml_skip(self, tmp_path): # Update pipeline_create_template_skip.yml file template_features_yml = load_features_yaml() - all_features = list(template_features_yml.keys()) + all_features = [] + for section in template_features_yml.values(): + all_features += list(section["features"].keys()) all_features.remove("is_nfcore") env = jinja2.Environment(loader=jinja2.PackageLoader("tests", "data"), keep_trailing_newline=True) skip_template = env.get_template( @@ -148,9 +150,10 @@ def test_template_customisation_all_files_grouping(self): "workflows/pipeline.nf", ] all_skipped_files = [] - for feature in template_features_yml.keys(): - if template_features_yml[feature]["skippable_paths"]: - all_skipped_files.extend(template_features_yml[feature]["skippable_paths"]) + for section in template_features_yml.values(): + for feature in section["features"].keys(): + if section["features"][feature]["skippable_paths"]: + all_skipped_files.extend(section["features"][feature]["skippable_paths"]) for root, _, files in os.walk(PIPELINE_TEMPLATE): for file in files: diff --git a/tests/pipelines/test_create_app.py b/tests/pipelines/test_create_app.py index d87d016b3e..abc4d56ef9 100644 --- a/tests/pipelines/test_create_app.py +++ b/tests/pipelines/test_create_app.py @@ -182,7 +182,8 @@ async def run_before(pilot) -> None: await pilot.press("tab") await pilot.press("M", "e") await pilot.click("#next") - await pilot.click("#igenomes") + await pilot.press("^p") + await pilot.click("#github_badges") await pilot.press("tab") await pilot.press("enter")