-
-
Notifications
You must be signed in to change notification settings - Fork 23
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
docs: completely revamp documentation
- Loading branch information
1 parent
0151931
commit dd9d3d7
Showing
25 changed files
with
414 additions
and
249 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
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 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,40 @@ | ||
.. include:: targets.rst | ||
|
||
.. _auto_detection: | ||
|
||
Auto-detection | ||
============== | ||
|
||
Root dir of the project | ||
----------------------- | ||
|
||
Nitpick_ tries to find the root dir of the project using some hardcoded assumptions. | ||
|
||
#. Starting from the current working directory, it will search for files that are usually in the root of a Python project: | ||
|
||
- ``pyproject.toml`` | ||
- ``setup.py`` | ||
- ``setup.cfg`` | ||
- ``requirements*.txt`` | ||
- ``Pipfile`` (Pipenv_) | ||
- ``app.py`` and ``wsgi.py`` (`Flask CLI`_) | ||
- ``autoapp.py`` | ||
|
||
#. If none of these root files were found, search for ``manage.py``. | ||
On Django_ projects, it can be in another dir inside the root dir (:issue:`21`). | ||
#. If multiple roots are found, get the top one in the dir tree. | ||
|
||
Main Python file | ||
---------------- | ||
|
||
After finding the `root dir of the project`_, Nitpick searches for a | ||
main Python file. | ||
Every project must have at least one ``*.py`` file, otherwise flake8_ won't even work. | ||
|
||
Those are the Python files that are considered: | ||
|
||
- ``setup.py`` | ||
- ``app.py`` and ``wsgi.py`` (`Flask CLI`_) | ||
- ``autoapp.py`` | ||
- ``manage.py`` | ||
- any ``*.py`` file |
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 |
---|---|---|
@@ -0,0 +1,85 @@ | ||
.. include:: targets.rst | ||
|
||
Nitpick | ||
======= | ||
|
||
.. image:: https://img.shields.io/pypi/v/nitpick.svg | ||
:target: https://pypi.org/project/nitpick/ | ||
:alt: PyPI | ||
.. image:: https://api.travis-ci.com/andreoliwa/nitpick.svg | ||
:target: https://travis-ci.com/andreoliwa/nitpick | ||
:alt: Travis CI | ||
.. image:: https://readthedocs.org/projects/nitpick/badge/?version=latest | ||
:target: https://nitpick.readthedocs.io/en/latest/?badge=latest | ||
:alt: Documentation Status | ||
.. image:: https://coveralls.io/repos/github/andreoliwa/nitpick/badge.svg | ||
:target: https://coveralls.io/github/andreoliwa/nitpick | ||
:alt: Coveralls | ||
.. image:: https://api.codeclimate.com/v1/badges/61e0cdc48e24e76a0460/maintainability | ||
:target: https://codeclimate.com/github/andreoliwa/nitpick | ||
:alt: Maintainability | ||
.. image:: https://api.codeclimate.com/v1/badges/61e0cdc48e24e76a0460/test_coverage | ||
:target: https://codeclimate.com/github/andreoliwa/nitpick | ||
:alt: Test Coverage | ||
.. image:: https://img.shields.io/pypi/pyversions/nitpick.svg | ||
:target: https://pypi.org/project/nitpick/ | ||
:alt: Supported Python versions | ||
.. image:: https://img.shields.io/pypi/l/nitpick.svg | ||
:target: https://pypi.org/project/nitpick/ | ||
:alt: Project License | ||
.. image:: https://img.shields.io/badge/code%20style-black-000000.svg | ||
:target: https://github.com/psf/black | ||
:alt: Code style: black | ||
.. image:: https://api.dependabot.com/badges/status?host=github&repo=andreoliwa/nitpick | ||
:target: https://dependabot.com | ||
:alt: Dependabot Status | ||
.. image:: https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg | ||
:target: https://github.com/semantic-release/semantic-release | ||
:alt: semantic-release | ||
|
||
Flake8 plugin to enforce the same tool configuration (flake8_, isort_, mypy_, Pylint_...) across multiple Python projects. | ||
|
||
Useful if you maintain multiple projects and want to use the same configs in all of them. | ||
|
||
.. note:: | ||
|
||
This project is still a work in progress, so the API is not fully defined: | ||
|
||
- :ref:`the-style-file` syntax might have changes before the 1.0 stable release. | ||
- The numbers in the ``NIP*`` error codes might change; don't fully rely on them. | ||
|
||
.. toctree:: | ||
:caption: Contents: | ||
|
||
installation_guide | ||
styles | ||
troubleshooting | ||
contributing | ||
authors | ||
|
||
.. toctree:: | ||
:caption: Configuration: | ||
|
||
auto_detection | ||
tool_nipick | ||
nitpick_section | ||
setup_cfg | ||
defaults | ||
|
||
.. toctree:: | ||
:maxdepth: 1 | ||
:caption: API: | ||
|
||
source/modules | ||
|
||
Indices and tables | ||
================== | ||
|
||
* :ref:`genindex` | ||
* :ref:`modindex` | ||
* :ref:`search` | ||
|
||
To Do List | ||
========== | ||
|
||
.. todolist:: |
Oops, something went wrong.