Add an example for using decman

This commit is contained in:
Kivi Kaitaniemi
2025-12-18 05:45:07 +02:00
parent 20171333ae
commit 1e3b83b3d8
15 changed files with 249 additions and 459 deletions
+10
View File
@@ -8,3 +8,13 @@ class Example(decman.Plugin):
def available(self) -> bool:
return os.path.exists("/tmp/example_plugin_available")
def process_modules(self, store: decman.Store, modules: set[decman.Module]):
# Toy example for setting modules as changed
for module in modules:
module._changed = True
def apply(
self, store: decman.Store, dry_run: bool = False, params: list[str] | None = None
) -> bool:
return True