Skip to main content

A plugin for poetry that allows you to execute scripts defined in your tasks.py using pyinvoke. Inspired by poetry-exec-plugin.

Project description

poetry-pyinvoke-plugin

A plugin for poetry that allows you to invoke commands in your tasks.py file delegating to pyinvoke.

Heavily inspired by the work from keattang on the poetry-exec-plugin project.

Installation

Installation requires poetry 1.2.0+. To install this plugin run:

pip install poetry-pyinvoke-plugin
# OR
poetry add -D poetry-pyinvoke-plugin

For other methods of installing plugins see the poetry documentation.

Usage

tasks.py

from invoke import task

@task
def lint(c):
  c.run("flake8")
  c.run("black --check .")

Then:

poetry invoke lint
# OR
poetry inv lint

Publishing

To publish a new version,first bump the package version in pyproject.toml and commit your changes to the main branch (via pull request). Then in GitHub create a new release with the new version as the tag and name. You can use the handy auto release notes feature to populate the release description.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

poetry-pyinvoke-plugin-0.1.1.tar.gz (3.5 kB view hashes)

Uploaded Source

Built Distribution

poetry_pyinvoke_plugin-0.1.1-py3-none-any.whl (3.9 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page