Metadata-Version: 2.1
Name: flake518
Version: 1.6.0
Summary: A small wrapper around flake8 to support PEP518 pyproject.toml as configuration file.
Home-page: https://github.com/carstencodes/flake518
Author-Email: Carsten Igel <cig@bite-that-bit.de>
License: MIT License
        
        Copyright (c) 2021 Carsten Igel
        
        Permission is hereby granted, free of charge, to any person obtaining a 
        copy of this software and associated documentation files (the "Software"), 
        to deal in the Software without restriction, including without limitation 
        the rights to use, copy, modify, merge, publish, distribute, sublicense, 
        and/or sell copies of the Software, and to permit persons to whom 
        the Software is furnished to do so, subject to the following conditions:
        
        The above copyright notice and this permission notice (including the 
        next paragraph) shall be included in all copies or substantial portions 
        of the Software.
        
        THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
        OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 
        MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
        IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY 
        CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, 
        TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE 
        SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Classifier: Development Status :: 5 - Production/Stable
Classifier: Environment :: Console
Classifier: Framework :: Flake8
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Classifier: Topic :: Software Development :: Quality Assurance
Classifier: Typing :: Typed
Project-URL: Homepage, https://github.com/carstencodes/flake518
Requires-Python: <4,>=3.9
Requires-Dist: tomli>=0.10.2; python_version < "3.11"
Requires-Dist: flake8>=3.0.0
Description-Content-Type: text/markdown

# Flake518

A small wrapper around the famous [flake8](https://flake8.pycqa.org/) tool empowering it to read
the configuration not from `setup.cfg`, `tox.ini` or `.flake8`, but from the [PEP518](https://www.python.org/dev/peps/pep-0518/)
compliant `pyproject.toml`.

In contrast to [flake9](https://gitlab.com/retnikt/flake9) it is not a fork of flake8. It uses flake8 under the hood and transforms
the relevant configuration to a flake8 configuration file. This way, the ongoing implementation of flake8 can be used.

## Rationale

The usage of `pyproject.toml` is though highly anticipated by some community members, but currently [rejected](https://github.com/PyCQA/flake8/issues/234) by the maintainers for an undisclosed reason. Flake9 already uses the `pyproject.toml` file, but does not incorporate later changes.

Since flake8 allows to pass additional configuration files, a temporary configuration file is created. This way, the latest flake8 revision is used, but it can be configured using `pyproject.toml`.

## Configuration

According to PEP518, each tool may add a tool-specific table to the project configuration.

```toml
[tool.flake8]
statistics=True
show-source=True
max-line-length=79
doctests=True
exclude=[".git", "__pypackages__", ".vscode", ".mypy_cache"]
```

For compliance reason, the `[tool.flake518]` can be used as well.

## Usage with the `pre-commit` git hooks framework

`flake518` can be included as a hook for [`pre-commit`](https://pre-commit.com/).
The easiest way to get started is to add this configuration to your `.pre-commit-config.yaml`:

```yaml
    -   repo: https://github.com/carstencodes/flake518
        rev: ''  # pick a git hash / tag to point to
        hooks:
        -   id: flake518
```

See the [`pre-commit`](https://pre-commit.com/#pre-commit-configyaml---hooks) for how to customize this configuration. 

## License

Like flake8, this project is licensed under the MIT license.

## Contributions

Contributions welcome, feel free to submit issues and pull requests on github.
Contact me, if you are using gitlab or codeberg.
