From 7f9f9adf0d8980184834d228ea6d5a65986ee1cb Mon Sep 17 00:00:00 2001 From: Sam Cunliffe Date: Tue, 23 Jan 2024 14:00:22 +0000 Subject: [PATCH] I forgot prettier. --- docs/pages/linting.md | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/docs/pages/linting.md b/docs/pages/linting.md index c7751522..4dbe6db0 100644 --- a/docs/pages/linting.md +++ b/docs/pages/linting.md @@ -9,21 +9,21 @@ See [here for example configuration](https://github.com/UCL-ARC/python-tooling/b ## Code formatting -| Name | Short description | 🚦 | Used by | -| -------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | --- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------: | -| [pre-commit](https://pre-commit.com/) | Universal tool which performs a git hook on commit, allows you to run linters/formatters on any code. A tool to automatically run many of the tools listed below. | 🟢 | [DiRAC](https://github.com/UCL-ARC/dirac-swift-api), [RRED](https://github.com/UCL-ARC/rred-reports), [Crabs Exploration](https://github.com/SainsburyWellcomeCentre/crabs-exploration) | -| [ruff-format](https://github.com/astral-sh/ruff) | A drop-in replacement for `black` (and also super fast). | 🟢 | | -| [ruff](https://github.com/astral-sh/ruff) | A very fast linter which incorporates a range of other linters. Note that [isort](https://pycqa.github.io/isort/) can be included as a [ruff rule](https://docs.astral.sh/ruff/rules/) (which we recommend). | 🟢 | [DiRAC](https://github.com/UCL-ARC/dirac-swift-api), [RRED](https://github.com/UCL-ARC/rred-reports), [Crabs Exploration](https://github.com/SainsburyWellcomeCentre/crabs-exploration) | -| [toml-sort](https://toml-sort.readthedocs.io/en/latest/) | Sorts TOML files which are now part of PEP 8. | 🟢 | | -| [autopep8](https://github.com/hhatto/autopep8) | Formatter which conforms to PEP 8. | 🟠 | | -| [black](https://black.readthedocs.io/en/stable/) | Opinionated formatter, defaults to 88 characters per line. | 🟠 | [DiRAC](https://github.com/UCL-ARC/dirac-swift-api), [Crabs Exploration](https://github.com/SainsburyWellcomeCentre/crabs-exploration), [autodE](https://github.com/duartegroup/autodE) | -| [isort](https://pycqa.github.io/isort/) | Sorts imports alphabetically, splits into first/third party, works on python & cython code. We recommend this, but it can be included in `ruff`, which is simpler. | 🟠 | | -| [pycodestyle](https://pycodestyle.pycqa.org/en/latest/) | Linter which checks for errors. | 🟠 | | -| [pyflakes](https://github.com/PyCQA/pyflakes) | Linter which checks for errors. | 🟠 | | -| [pylint](https://pylint.readthedocs.io/en/latest/) | Linter which checks for errors. | 🟠 | | -| [sourcery](https://sourcery.ai/) | An AI code reviewer which simplifies code, has a free version but can pay for fancier features. | 🟠 | | -| [yapf](https://github.com/google/yapf) | Google formatter. | 🟠 | | -| [flake8](https://flake8.pycqa.org/en/latest/) | Linter which complains if code doesn't follow a rule. Does not support modern `pyproject.toml` configuration. | 🔴 | | +| Name | Short description | 🚦 | Used by | +| -------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | --- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------: | +| [pre-commit](https://pre-commit.com/) | Universal tool which performs a git hook on commit, allows you to run linters/formatters on any code. A tool to automatically run many of the tools listed below. | 🟢 | [DiRAC](https://github.com/UCL-ARC/dirac-swift-api), [RRED](https://github.com/UCL-ARC/rred-reports), [Crabs Exploration](https://github.com/SainsburyWellcomeCentre/crabs-exploration) | +| [ruff-format](https://github.com/astral-sh/ruff) | A drop-in replacement for `black` (and also super fast). | 🟢 | | +| [ruff](https://github.com/astral-sh/ruff) | A very fast linter which incorporates a range of other linters. Note that [isort](https://pycqa.github.io/isort/) can be included as a [ruff rule](https://docs.astral.sh/ruff/rules/) (which we recommend). | 🟢 | [DiRAC](https://github.com/UCL-ARC/dirac-swift-api), [RRED](https://github.com/UCL-ARC/rred-reports), [Crabs Exploration](https://github.com/SainsburyWellcomeCentre/crabs-exploration) | +| [toml-sort](https://toml-sort.readthedocs.io/en/latest/) | Sorts TOML files which are now part of PEP 8. | 🟢 | | +| [autopep8](https://github.com/hhatto/autopep8) | Formatter which conforms to PEP 8. | 🟠 | | +| [black](https://black.readthedocs.io/en/stable/) | Opinionated formatter, defaults to 88 characters per line. | 🟠 | [DiRAC](https://github.com/UCL-ARC/dirac-swift-api), [Crabs Exploration](https://github.com/SainsburyWellcomeCentre/crabs-exploration), [autodE](https://github.com/duartegroup/autodE) | +| [isort](https://pycqa.github.io/isort/) | Sorts imports alphabetically, splits into first/third party, works on python & cython code. We recommend this, but it can be included in `ruff`, which is simpler. | 🟠 | | +| [pycodestyle](https://pycodestyle.pycqa.org/en/latest/) | Linter which checks for errors. | 🟠 | | +| [pyflakes](https://github.com/PyCQA/pyflakes) | Linter which checks for errors. | 🟠 | | +| [pylint](https://pylint.readthedocs.io/en/latest/) | Linter which checks for errors. | 🟠 | | +| [sourcery](https://sourcery.ai/) | An AI code reviewer which simplifies code, has a free version but can pay for fancier features. | 🟠 | | +| [yapf](https://github.com/google/yapf) | Google formatter. | 🟠 | | +| [flake8](https://flake8.pycqa.org/en/latest/) | Linter which complains if code doesn't follow a rule. Does not support modern `pyproject.toml` configuration. | 🔴 | |
🟢 explanation