every libs/*.py and hooks/*.py now starts with a one-line module docstring; every bin/* script starts with a `# purpose:` header. discovery-by-`ls`-and-read instead of by index. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
11 lines
297 B
Python
11 lines
297 B
Python
"""wake_on_lan: pre-apply / pre-run hook that wakes a node via libs.wol before bw connects to it."""
|
|
|
|
|
|
def wake_on_lan(node):
|
|
node.repo.libs.wol.wake(node)
|
|
|
|
def node_apply_start(repo, node, **kwargs):
|
|
wake_on_lan(node)
|
|
|
|
def node_run_start(repo, node, cmd, **kwargs):
|
|
wake_on_lan(node)
|