diff options
Diffstat (limited to '.ai/scripts')
| -rwxr-xr-x | .ai/scripts/broadcast.py (renamed from .ai/scripts/cross-project-broadcast.py) | 8 | ||||
| -rw-r--r-- | .ai/scripts/tests/test_broadcast.py (renamed from .ai/scripts/tests/test_cross_project_broadcast.py) | 6 |
2 files changed, 7 insertions, 7 deletions
diff --git a/.ai/scripts/cross-project-broadcast.py b/.ai/scripts/broadcast.py index 2c4c690..ba5c786 100755 --- a/.ai/scripts/cross-project-broadcast.py +++ b/.ai/scripts/broadcast.py @@ -6,8 +6,8 @@ whose .ai/protocols.org exists. Uses the existing inbox-send.py helper to deliver per-target. Usage: - cross-project-broadcast.py --list - cross-project-broadcast.py --file <path> [--exclude <name> ...] [--dry-run] + broadcast.py --list + broadcast.py --file <path> [--exclude <name> ...] [--dry-run] """ from __future__ import annotations @@ -67,7 +67,7 @@ def inbox_send_path() -> Path: candidate = ancestor / ".ai" / "scripts" / "inbox-send.py" if candidate.is_file(): return candidate - raise SystemExit("cross-project-broadcast: inbox-send.py not found in current project") + raise SystemExit("broadcast: inbox-send.py not found in current project") def main() -> int: @@ -115,7 +115,7 @@ def main() -> int: msg_path = Path(args.file).resolve() if not msg_path.is_file(): - print(f"cross-project-broadcast: file not found: {msg_path}", file=sys.stderr) + print(f"broadcast: file not found: {msg_path}", file=sys.stderr) return 2 inbox_send = inbox_send_path() diff --git a/.ai/scripts/tests/test_cross_project_broadcast.py b/.ai/scripts/tests/test_broadcast.py index 5919fbf..a0decf5 100644 --- a/.ai/scripts/tests/test_cross_project_broadcast.py +++ b/.ai/scripts/tests/test_broadcast.py @@ -1,4 +1,4 @@ -"""Tests for cross-project-broadcast.py: project fingerprinting + discovery. +"""Tests for broadcast.py: project fingerprinting + discovery. Plain python3 script. The pure-ish helpers are driven against tmp project trees; discovery is exercised with SEARCH_ROOTS monkeypatched to the tree, and @@ -11,12 +11,12 @@ from pathlib import Path import pytest -SCRIPT = Path(__file__).resolve().parents[1] / "cross-project-broadcast.py" +SCRIPT = Path(__file__).resolve().parents[1] / "broadcast.py" @pytest.fixture(scope="module") def bcast(): - spec = importlib.util.spec_from_file_location("cross_project_broadcast", SCRIPT) + spec = importlib.util.spec_from_file_location("broadcast", SCRIPT) assert spec and spec.loader module = importlib.util.module_from_spec(spec) spec.loader.exec_module(module) |
