delfino-core


Namedelfino-core JSON
Version 7.2.3 PyPI version JSON
download
home_pagehttps://github.com/radeklat/delfino-core
SummaryDelfino core plugin
upload_time2024-01-23 13:29:16
maintainer
docs_urlNone
authorRadek Lát
requires_python>=3.8.1,<4.0.0
licenseMIT
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            <h1 align="center" style="border-bottom: none;"> 🔌&nbsp;&nbsp;Delfino Core&nbsp;&nbsp; 🔌</h1>
<h3 align="center">A <a href="https://github.com/radeklat/delfino">Delfino</a> plugin with core functionality.</h3>

<p align="center">
    <a href="https://app.circleci.com/pipelines/github/radeklat/delfino-core?branch=main">
        <img alt="CircleCI" src="https://img.shields.io/circleci/build/github/radeklat/delfino-core">
    </a>
    <a href="https://app.codecov.io/gh/radeklat/delfino-core/">
        <img alt="Codecov" src="https://img.shields.io/codecov/c/github/radeklat/delfino-core">
    </a>
    <a href="https://github.com/radeklat/delfino-core/tags">
        <img alt="GitHub tag (latest SemVer)" src="https://img.shields.io/github/tag/radeklat/delfino-core">
    </a>
    <img alt="Maintenance" src="https://img.shields.io/maintenance/yes/2024">
    <a href="https://github.com/radeklat/delfino-core/commits/main">
        <img alt="GitHub last commit" src="https://img.shields.io/github/last-commit/radeklat/delfino-core">
    </a>
    <a href="https://www.python.org/doc/versions/">
        <img alt="PyPI - Python Version" src="https://img.shields.io/pypi/pyversions/delfino-core">
    </a>
    <a href="https://pypistats.org/packages/delfino-core">
        <img alt="Downloads" src="https://img.shields.io/pypi/dm/delfino-core">
    </a>
</p>

# Commands
  
| Command               | Description                                         |
|-----------------------|-----------------------------------------------------|
| black                 | Runs black.                                         |
| coverage-open         | Open coverage results in default browser.           |
| coverage-report       | Analyse coverage and generate a term/HTML report.   |
| dependencies-update   | Manages the process of updating dependencies.       |
| ensure-pre-commit     | Ensures pre-commit is installed and enabled.        |
| format                | Runs ensure-pre-commit, pyupgrade, isort, black.    |
| isort                 | Runs isort.                                         |
| lint                  | Runs pylint, pycodestyle, pydocstyle.               |
| pre-commit            | Run all pre-commit stages in the current project.   |
| pycodestyle           | Run PEP8 checking on code.                          |
| pydocstyle            | Run docstring linting on source code.               |
| pylint                | Run pylint on code.                                 |
| pytest                | Runs pytest for individual test suites.             |
| pytest-integration    | Run integration tests.                              |
| pytest-unit           | Run unit tests.                                     |
| pyupgrade             | Runs pyupgrade with automatic version discovery.    |
| switch-python-version | Switches Python venv to a different Python version. |
| test                  | Runs pytest, coverage-report.                       |
| mypy                  | Run type checking on source code.                   |
| verify                | Runs format, lint, mypy, test-all.                  |

# Installation

- pip: `pip install delfino-core`
- Poetry: `poetry add -D delfino-core`
- Pipenv: `pipenv install -d delfino-core`

## Optional dependencies

Each project may use different sub-set of [commands](#commands). Therefore, dependencies of all commands are optional and checked only when the command is executed.

Using `[all]` installs all the [optional dependencies](https://setuptools.pypa.io/en/latest/userguide/dependency_management.html#optional-dependencies) used by all the commands. If you want only a sub-set of those dependencies, there are finer-grained groups available:

- For individual commands (matches the command names):
  - `mypy`
  - `format`
  - `dependencies-update`
  - `pre-commit`
- For groups of commands:
  - `test` - for testing and coverage commands
  - `lint` - for all the linting commands
- For groups of groups:
  - `verify` - same as `[mypy,format,test,lint]`
  - `all` - all optional packages

# Configuration

Delfino doesn't load any plugins by default. To enable this plugin, add the following config into `pyproject.toml`:

```toml
[tool.delfino.plugins.delfino-core]

```

## Plugin configuration

This plugin has several options. All the values are optional and defaults are shown below: 

```toml
[tool.delfino.plugins.delfino-core]
# Source files - may have different rules than tests (usually stricter)
sources_directory = "src"

# Test files
tests_directory = "tests"

# Where to store reports generated by various tools
reports_directory = "reports"

# Types of tests you have nested under the `tests_directory`. Will be executed in given order.
test_types = ["unit", "integration"]

# One or more module to wrap `pytest` in, executing it as `python -m <MODULE> pytest ...`
pytest_modules = []

# Commands to run as a quality gate in given order.
verify_commands = ["format", "lint", "mypy", "test-all"]

# Do not install pre-commit if this is set to true.
disable_pre_commit = false
```

## Commands configuration

Several commands have their own configuration as well:

```toml
[tool.delfino.plugins.delfino-core.mypy]
# One or more directories where type hint will be required. By default they are optional.
strict_directories = []  
```

# Usage

Run `delfino --help`.

# Development

To develop against editable `delfino` sources:

1. Make sure `delfino` sources are next to this plugin:
    ```shell
    cd ..
    git clone https://github.com/radeklat/delfino.git
    ```
2. Install `delfino` as editable package:
    ```shell
    pip install -e ../delfino
    ```
   Note that poetry will reset this to the released package when you install/update anything.

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/radeklat/delfino-core",
    "name": "delfino-core",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.8.1,<4.0.0",
    "maintainer_email": "",
    "keywords": "",
    "author": "Radek L\u00e1t",
    "author_email": "radek.lat@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/ec/c2/8020b15a75fe03959038d01f73118aec8883d1912869f8194143ad358717/delfino_core-7.2.3.tar.gz",
    "platform": null,
    "description": "<h1 align=\"center\" style=\"border-bottom: none;\"> \ud83d\udd0c&nbsp;&nbsp;Delfino Core&nbsp;&nbsp; \ud83d\udd0c</h1>\n<h3 align=\"center\">A <a href=\"https://github.com/radeklat/delfino\">Delfino</a> plugin with core functionality.</h3>\n\n<p align=\"center\">\n    <a href=\"https://app.circleci.com/pipelines/github/radeklat/delfino-core?branch=main\">\n        <img alt=\"CircleCI\" src=\"https://img.shields.io/circleci/build/github/radeklat/delfino-core\">\n    </a>\n    <a href=\"https://app.codecov.io/gh/radeklat/delfino-core/\">\n        <img alt=\"Codecov\" src=\"https://img.shields.io/codecov/c/github/radeklat/delfino-core\">\n    </a>\n    <a href=\"https://github.com/radeklat/delfino-core/tags\">\n        <img alt=\"GitHub tag (latest SemVer)\" src=\"https://img.shields.io/github/tag/radeklat/delfino-core\">\n    </a>\n    <img alt=\"Maintenance\" src=\"https://img.shields.io/maintenance/yes/2024\">\n    <a href=\"https://github.com/radeklat/delfino-core/commits/main\">\n        <img alt=\"GitHub last commit\" src=\"https://img.shields.io/github/last-commit/radeklat/delfino-core\">\n    </a>\n    <a href=\"https://www.python.org/doc/versions/\">\n        <img alt=\"PyPI - Python Version\" src=\"https://img.shields.io/pypi/pyversions/delfino-core\">\n    </a>\n    <a href=\"https://pypistats.org/packages/delfino-core\">\n        <img alt=\"Downloads\" src=\"https://img.shields.io/pypi/dm/delfino-core\">\n    </a>\n</p>\n\n# Commands\n  \n| Command               | Description                                         |\n|-----------------------|-----------------------------------------------------|\n| black                 | Runs black.                                         |\n| coverage-open         | Open coverage results in default browser.           |\n| coverage-report       | Analyse coverage and generate a term/HTML report.   |\n| dependencies-update   | Manages the process of updating dependencies.       |\n| ensure-pre-commit     | Ensures pre-commit is installed and enabled.        |\n| format                | Runs ensure-pre-commit, pyupgrade, isort, black.    |\n| isort                 | Runs isort.                                         |\n| lint                  | Runs pylint, pycodestyle, pydocstyle.               |\n| pre-commit            | Run all pre-commit stages in the current project.   |\n| pycodestyle           | Run PEP8 checking on code.                          |\n| pydocstyle            | Run docstring linting on source code.               |\n| pylint                | Run pylint on code.                                 |\n| pytest                | Runs pytest for individual test suites.             |\n| pytest-integration    | Run integration tests.                              |\n| pytest-unit           | Run unit tests.                                     |\n| pyupgrade             | Runs pyupgrade with automatic version discovery.    |\n| switch-python-version | Switches Python venv to a different Python version. |\n| test                  | Runs pytest, coverage-report.                       |\n| mypy                  | Run type checking on source code.                   |\n| verify                | Runs format, lint, mypy, test-all.                  |\n\n# Installation\n\n- pip: `pip install delfino-core`\n- Poetry: `poetry add -D delfino-core`\n- Pipenv: `pipenv install -d delfino-core`\n\n## Optional dependencies\n\nEach project may use different sub-set of [commands](#commands). Therefore, dependencies of all commands are optional and checked only when the command is executed.\n\nUsing `[all]` installs all the [optional dependencies](https://setuptools.pypa.io/en/latest/userguide/dependency_management.html#optional-dependencies) used by all the commands. If you want only a sub-set of those dependencies, there are finer-grained groups available:\n\n- For individual commands (matches the command names):\n  - `mypy`\n  - `format`\n  - `dependencies-update`\n  - `pre-commit`\n- For groups of commands:\n  - `test` - for testing and coverage commands\n  - `lint` - for all the linting commands\n- For groups of groups:\n  - `verify` - same as `[mypy,format,test,lint]`\n  - `all` - all optional packages\n\n# Configuration\n\nDelfino doesn't load any plugins by default. To enable this plugin, add the following config into `pyproject.toml`:\n\n```toml\n[tool.delfino.plugins.delfino-core]\n\n```\n\n## Plugin configuration\n\nThis plugin has several options. All the values are optional and defaults are shown below: \n\n```toml\n[tool.delfino.plugins.delfino-core]\n# Source files - may have different rules than tests (usually stricter)\nsources_directory = \"src\"\n\n# Test files\ntests_directory = \"tests\"\n\n# Where to store reports generated by various tools\nreports_directory = \"reports\"\n\n# Types of tests you have nested under the `tests_directory`. Will be executed in given order.\ntest_types = [\"unit\", \"integration\"]\n\n# One or more module to wrap `pytest` in, executing it as `python -m <MODULE> pytest ...`\npytest_modules = []\n\n# Commands to run as a quality gate in given order.\nverify_commands = [\"format\", \"lint\", \"mypy\", \"test-all\"]\n\n# Do not install pre-commit if this is set to true.\ndisable_pre_commit = false\n```\n\n## Commands configuration\n\nSeveral commands have their own configuration as well:\n\n```toml\n[tool.delfino.plugins.delfino-core.mypy]\n# One or more directories where type hint will be required. By default they are optional.\nstrict_directories = []  \n```\n\n# Usage\n\nRun `delfino --help`.\n\n# Development\n\nTo develop against editable `delfino` sources:\n\n1. Make sure `delfino` sources are next to this plugin:\n    ```shell\n    cd ..\n    git clone https://github.com/radeklat/delfino.git\n    ```\n2. Install `delfino` as editable package:\n    ```shell\n    pip install -e ../delfino\n    ```\n   Note that poetry will reset this to the released package when you install/update anything.\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Delfino core plugin",
    "version": "7.2.3",
    "project_urls": {
        "Homepage": "https://github.com/radeklat/delfino-core"
    },
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "e7ba8d4cbc7a92231c412aba80fe4ced237dbaf13566ff5cd2dab56f9dc2c3c4",
                "md5": "061e8d14bfd63426fbee0fc8ea239df8",
                "sha256": "a463b3cfdb8447008f96a9dc272a3e598d6de7d69b42154480ec007c0b1f2ab3"
            },
            "downloads": -1,
            "filename": "delfino_core-7.2.3-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "061e8d14bfd63426fbee0fc8ea239df8",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8.1,<4.0.0",
            "size": 26190,
            "upload_time": "2024-01-23T13:29:14",
            "upload_time_iso_8601": "2024-01-23T13:29:14.966714Z",
            "url": "https://files.pythonhosted.org/packages/e7/ba/8d4cbc7a92231c412aba80fe4ced237dbaf13566ff5cd2dab56f9dc2c3c4/delfino_core-7.2.3-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "ecc28020b15a75fe03959038d01f73118aec8883d1912869f8194143ad358717",
                "md5": "3d638455e72b69ecee7b0bf3b2c4152a",
                "sha256": "05d3a0b00e4d5e1cb898d8214231557807980dc03cd8d28d0f140ad57466b1de"
            },
            "downloads": -1,
            "filename": "delfino_core-7.2.3.tar.gz",
            "has_sig": false,
            "md5_digest": "3d638455e72b69ecee7b0bf3b2c4152a",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8.1,<4.0.0",
            "size": 22169,
            "upload_time": "2024-01-23T13:29:16",
            "upload_time_iso_8601": "2024-01-23T13:29:16.537764Z",
            "url": "https://files.pythonhosted.org/packages/ec/c2/8020b15a75fe03959038d01f73118aec8883d1912869f8194143ad358717/delfino_core-7.2.3.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-01-23 13:29:16",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "radeklat",
    "github_project": "delfino-core",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "circle": true,
    "lcname": "delfino-core"
}
        
Elapsed time: 0.18934s