doitoml#
Load declarative tasks for doit from TOML, JSON, YAML, and other files.
docs |
install |
build |
|---|---|---|
See the full documentation for more information.
Install#
|
|
|---|---|
|
|
Features#
declarative automation in a single
pyproject.toml, or…other well-known configuration paths like
package.jsonany number of namespaced TOML, JSON, YAML files
from any key inside them
augment and simplify existing
dodo.pyworkflows
reuse and transform paths and shell tokens
use globs and transforms to capture relationships between transformed files
flexibly configure environment variables
user-defined Python-based actions and up-to-date checkers
control the working directory and log paths of processes and actions
use templates like Jinja2 and JSON-e for advanced use cases
extensibility in any part of the task definition process
all core functionality implemented as
entry_point-based plugins
Extras#
These features require additional pip or conda packages
|
|
feature |
|---|---|---|
|
|
all optional features |
|
|
Jinja2 task templates |
|
|
JSON-e task templates |
|
|
extra configuration validation |
|
|
YAML-based task sources |
Usage#
doitoml provides no additional command line abilities, and is meant to drop in to the
existing doit run CLI and
other commands.
A Simple Example#
Note
The
doitomlGitHub repository has many examples of different configurations, including the project’s ownpyproject.tomlandpackage.json.The full documentation includes more information about building concise, declarative, reproducible tasks for your project.
The simplest way to use doitoml needs only a pyproject.toml, which doit will
already check for configuration data.
# pyproject.toml
[project.optional-dependencies]
dev = ["doitoml"]
[tool.doit]
loader = "doitoml"
verbosity = 2
[tool.doitoml.tasks.hello]
actions = ['echo "Hello World!"']
After installing the dev extra dependency…
pip install -e .[dev]
… and running …
doit
… you would see …
. hello:
Hello World!
Alternatives#
If you don’t like doitoml, or doit, or even Python, no worries! But please
consider trying one of these lovely alternatives before giving up and making your team
do everything The Hard Way:
Free Software#
doitoml is licensed under the BSD-3-Clause License.