-
Notifications
You must be signed in to change notification settings - Fork 192
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #809 from ewels/lint-refactoring
Lint refactoring
- Loading branch information
Showing
108 changed files
with
3,394 additions
and
3,182 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,6 +2,7 @@ | |
|
||
.coverage | ||
.pytest_cache | ||
docs/api/_build | ||
|
||
# Byte-compiled / optimized / DLL files | ||
__pycache__/ | ||
|
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
API Reference | ||
============= | ||
|
||
.. toctree:: | ||
:maxdepth: 2 | ||
:caption: Tests: | ||
:glob: | ||
|
||
* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
nf_core.launch | ||
============ | ||
============== | ||
|
||
.. automodule:: nf_core.launch | ||
:members: | ||
|
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
nf_core.lint | ||
============ | ||
|
||
.. seealso:: See the `Lint Tests <../lint_tests/index.html>`_ docs for information about specific linting functions. | ||
|
||
.. automodule:: nf_core.lint | ||
:members: run_linting | ||
:undoc-members: | ||
:show-inheritance: | ||
|
||
.. autoclass:: nf_core.lint.PipelineLint | ||
:members: _lint_pipeline | ||
:private-members: _print_results, _get_results_md, _save_json_results, _wrap_quotes, _strip_ansi_codes | ||
:show-inheritance: |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
nf_core.modules | ||
============ | ||
=============== | ||
|
||
.. automodule:: nf_core.modules | ||
:members: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
nf_core.schema | ||
============ | ||
============== | ||
|
||
.. automodule:: nf_core.schema | ||
:members: | ||
|
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
actions_awsfulltest | ||
=================== | ||
|
||
.. automethod:: nf_core.lint.PipelineLint.actions_awsfulltest |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
actions_awstest | ||
=============== | ||
|
||
.. automethod:: nf_core.lint.PipelineLint.actions_awstest |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
actions_branch_protection | ||
========================= | ||
|
||
.. automethod:: nf_core.lint.PipelineLint.actions_branch_protection |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
actions_ci | ||
========== | ||
|
||
.. automethod:: nf_core.lint.PipelineLint.actions_ci |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
actions_lint | ||
============ | ||
|
||
.. automethod:: nf_core.lint.PipelineLint.actions_lint |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
conda_dockerfile | ||
================ | ||
|
||
.. automethod:: nf_core.lint.PipelineLint.conda_dockerfile |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
conda_env_yaml | ||
============== | ||
|
||
.. automethod:: nf_core.lint.PipelineLint.conda_env_yaml | ||
.. automethod:: nf_core.lint.PipelineLint._anaconda_package | ||
.. automethod:: nf_core.lint.PipelineLint._pip_package |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
cookiecutter_strings | ||
==================== | ||
|
||
.. automethod:: nf_core.lint.PipelineLint.cookiecutter_strings |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
files_exist | ||
=========== | ||
|
||
.. automethod:: nf_core.lint.PipelineLint.files_exist |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
Lint tests | ||
============================================ | ||
|
||
.. toctree:: | ||
:maxdepth: 2 | ||
:caption: Tests: | ||
:glob: | ||
|
||
* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
licence | ||
======= | ||
|
||
.. automethod:: nf_core.lint.PipelineLint.licence |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
nextflow_config | ||
=============== | ||
|
||
.. automethod:: nf_core.lint.PipelineLint.nextflow_config |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
pipeline_name_conventions | ||
========================= | ||
|
||
.. automethod:: nf_core.lint.PipelineLint.pipeline_name_conventions |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
pipeline_todos | ||
============== | ||
|
||
.. automethod:: nf_core.lint.PipelineLint.pipeline_todos |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
readme | ||
====== | ||
|
||
.. automethod:: nf_core.lint.PipelineLint.readme |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
schema_lint | ||
=========== | ||
|
||
.. automethod:: nf_core.lint.PipelineLint.schema_lint |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
schema_params | ||
============= | ||
|
||
.. automethod:: nf_core.lint.PipelineLint.schema_params |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
version_consistency | ||
=================== | ||
|
||
.. automethod:: nf_core.lint.PipelineLint.version_consistency |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
#!/usr/bin/env python | ||
|
||
import fnmatch | ||
import os | ||
import nf_core.lint | ||
|
||
docs_basedir = os.path.join(os.path.dirname(os.path.abspath(__file__)), "_src", "lint_tests") | ||
|
||
# Get list of existing .rst files | ||
existing_docs = [] | ||
for fn in os.listdir(docs_basedir): | ||
if fnmatch.fnmatch(fn, "*.rst") and not fnmatch.fnmatch(fn, "index.rst"): | ||
existing_docs.append(os.path.join(docs_basedir, fn)) | ||
|
||
# Make .rst file for each test name | ||
lint_obj = nf_core.lint.PipelineLint("", True) | ||
rst_template = """{0} | ||
{1} | ||
.. automethod:: nf_core.lint.PipelineLint.{0} | ||
""" | ||
|
||
for test_name in lint_obj.lint_tests: | ||
fn = os.path.join(docs_basedir, "{}.rst".format(test_name)) | ||
if os.path.exists(fn): | ||
existing_docs.remove(fn) | ||
else: | ||
with open(fn, "w") as fh: | ||
fh.write(rst_template.format(test_name, len(test_name) * "=")) | ||
|
||
for fn in existing_docs: | ||
os.remove(fn) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
Sphinx>=3.3.1 | ||
sphinx_rtd_theme>=0.5.0 |
Oops, something went wrong.