Skip to content

Why plugins?

You have multiple projects/repositories, and you have very similar or identical deployment, testing, and linting rules.

You have multiple open source repositories, and you would like to maintain the same standards for each and avoid tedious and repeated setup tasks for them.

What is a plugin?

jeeves plugin is an installable Python package which declares jeeves commands. You do not need to copy jeeves.py from one project to another; you can define a plugin with reusable commands, and install that plugin as dev dependency.

Plugin example: jeeves-yeti-pyproject

This is a custom plugin created to manage my own open source projects.

  • It brings pytest and a few plugins for it as dependencies; j test command tests Python code exactly as I like it to be tested
  • It also has a number of linters and flake8 plugins, j lint uses a shared configuration for those
  • I no longer have to install all those dev dependencies for every new project and to copy-paste their configuration files
  • If one plugin conflicts with another, I resolve the issue only once and then just poetry update all my projects
poetry add --group dev jeeves-yeti-pyproject

Top level documentation

j
 Usage: j [OPTIONS] COMMAND [ARGS]...                                           

 Manage a Python project.                                                       

╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --log-level                 [debug|info|error]  Logging level.               │
│                                                 [default: LogLevel.ERROR]    │
│ --install-completion                            Install completion for the   │
│                                                 current shell.               │
│ --show-completion                               Show completion for the      │
│                                                 current shell, to copy it or │
│                                                 customize the installation.  │
│ --help                                          Show this message and exit.  │
╰──────────────────────────────────────────────────────────────────────────────╯
╭─ Commands ───────────────────────────────────────────────────────────────────╮
│ clear-poetry-cache       Clear Poetry cache.                                 │
│ commit                   Create a commit.                                    │
│ cover-image              Generate cover image for the front page.            │
│ deploy-to-github-pages   Build the docs & deploy → gh-pages branch.          │
│ fmt                      Auto format code.                                   │
│ install-graphviz         Install graphviz, which is a prerequisite for some  │
│                          helper packages.                                    │
│ install-mkdocs-insiders  Install Insiders version of `mkdocs-material`       │
│                          theme.                                              │
│ lint                     Lint code.                                          │
│ safety                   Check installed Python packages for                 │
│                          vulnerabilities.                                    │
│ serve                    Serve documentation locally.                        │
│ test                     Unit test code.                                     │
╰──────────────────────────────────────────────────────────────────────────────╯