diff options
-rwxr-xr-x | poe | 2 | ||||
-rw-r--r-- | pyproject.toml | 3 | ||||
-rwxr-xr-x | scripts/poe-tasks/kresctl | 8 |
3 files changed, 10 insertions, 3 deletions
@@ -19,4 +19,4 @@ else echo "poethepoet version - must be >=0.22.0" >&2 echo "Python version - must be >=3.8" >&2 exit 1 -fi +fi
\ No newline at end of file diff --git a/pyproject.toml b/pyproject.toml index 81b7a960..2a4bedf2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -82,8 +82,7 @@ gen-setuppy = { cmd = "scripts/poe-tasks/gen-setuppy", help = "Generate 'setup.p format = { cmd = "scripts/poe-tasks/format", help = "Run code formatter" } # tasks runned directly fixdeps = { shell = "poetry install; npm install; npm update", help = "Install/update dependencies according to configuration files"} -kresctl = { script = "knot_resolver_manager.cli.main:main", cwd="${POE_PWD}", help="Run kresctl utility" } -kresctl-nocwd = { script = "knot_resolver_manager.cli.main:main", help="Run kresctl utility" } # Python <3.8 and poethepoet <0.22.0 compatibility (see also `./poe`) +kresctl = { cmd = "scripts/poe-tasks/kresctl", help="Run kresctl utility" } clean = """ rm -rf .coverage .mypy_cache diff --git a/scripts/poe-tasks/kresctl b/scripts/poe-tasks/kresctl new file mode 100755 index 00000000..4b4880b7 --- /dev/null +++ b/scripts/poe-tasks/kresctl @@ -0,0 +1,8 @@ +#!/bin/bash + +# ensure consistent behaviour +src_dir="$(dirname "$(realpath "$0")")" +source $src_dir/_env.sh + +# run knot-resolver client +python3 -m knot_resolver_manager.cli $@ |