Skip to content

Commit ae601f3

Browse files
committed
Remove plugin stuff from invoke tasks.py file
1 parent 3f77816 commit ae601f3

File tree

1 file changed

+6
-10
lines changed

1 file changed

+6
-10
lines changed

tasks.py

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,6 @@
1515

1616
import invoke
1717
from invoke.context import Context
18-
from plugins import (
19-
tasks as plugin_tasks,
20-
)
2118

2219
TASK_ROOT = pathlib.Path(__file__).resolve().parent
2320
TASK_ROOT_STR = str(TASK_ROOT)
@@ -39,7 +36,7 @@ def rmrf(items: str | list[str] | set[str], verbose: bool = True) -> None:
3936

4037

4138
# create namespaces
42-
namespace = invoke.Collection(plugin=plugin_tasks)
39+
namespace = invoke.Collection()
4340
namespace_clean = invoke.Collection('clean')
4441
namespace.add_collection(namespace_clean, 'clean')
4542

@@ -68,7 +65,7 @@ def pytest(context: Context, junit: bool = False, pty: bool = True) -> None:
6865
namespace.add_task(pytest)
6966

7067

71-
@invoke.task(post=[plugin_tasks.pytest_clean])
68+
@invoke.task()
7269
def pytest_clean(context: Context) -> None:
7370
"""Remove pytest cache and code coverage files and directories."""
7471
# pylint: disable=unused-argument
@@ -152,7 +149,7 @@ def livehtml(context: Context) -> None:
152149
DISTDIR = 'dist'
153150

154151

155-
@invoke.task(post=[plugin_tasks.build_clean])
152+
@invoke.task()
156153
def build_clean(context: Context) -> None:
157154
"""Remove the build directory."""
158155
# pylint: disable=unused-argument
@@ -163,7 +160,7 @@ def build_clean(context: Context) -> None:
163160
namespace_clean.add_task(build_clean, 'build')
164161

165162

166-
@invoke.task(post=[plugin_tasks.dist_clean])
163+
@invoke.task()
167164
def dist_clean(context: Context) -> None:
168165
"""Remove the dist directory."""
169166
# pylint: disable=unused-argument
@@ -242,7 +239,6 @@ def ruff_clean(context: Context) -> None:
242239
#
243240
# make a dummy clean task which runs all the tasks in the clean namespace
244241
clean_tasks = list(namespace_clean.tasks.values())
245-
clean_tasks.append(plugin_tasks.clean_all)
246242

247243

248244
@invoke.task(pre=clean_tasks, default=True)
@@ -286,7 +282,7 @@ def validatetag(context: Context) -> None:
286282
namespace.add_task(validatetag)
287283

288284

289-
@invoke.task(pre=[clean_all], post=[plugin_tasks.sdist])
285+
@invoke.task(pre=[clean_all])
290286
def sdist(context: Context) -> None:
291287
"""Create a source distribution."""
292288
with context.cd(TASK_ROOT_STR):
@@ -296,7 +292,7 @@ def sdist(context: Context) -> None:
296292
namespace.add_task(sdist)
297293

298294

299-
@invoke.task(pre=[clean_all], post=[plugin_tasks.wheel])
295+
@invoke.task(pre=[clean_all])
300296
def wheel(context: Context) -> None:
301297
"""Build a wheel distribution."""
302298
with context.cd(TASK_ROOT_STR):

0 commit comments

Comments
 (0)