conduct-cli 0.4.24__tar.gz → 0.4.26__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {conduct_cli-0.4.24 → conduct_cli-0.4.26}/PKG-INFO +1 -1
- {conduct_cli-0.4.24 → conduct_cli-0.4.26}/pyproject.toml +1 -1
- {conduct_cli-0.4.24 → conduct_cli-0.4.26}/src/conduct_cli/guard.py +18 -1
- {conduct_cli-0.4.24 → conduct_cli-0.4.26}/src/conduct_cli.egg-info/PKG-INFO +1 -1
- {conduct_cli-0.4.24 → conduct_cli-0.4.26}/README.md +0 -0
- {conduct_cli-0.4.24 → conduct_cli-0.4.26}/setup.cfg +0 -0
- {conduct_cli-0.4.24 → conduct_cli-0.4.26}/setup.py +0 -0
- {conduct_cli-0.4.24 → conduct_cli-0.4.26}/src/conduct_cli/__init__.py +0 -0
- {conduct_cli-0.4.24 → conduct_cli-0.4.26}/src/conduct_cli/api.py +0 -0
- {conduct_cli-0.4.24 → conduct_cli-0.4.26}/src/conduct_cli/guardmcp.py +0 -0
- {conduct_cli-0.4.24 → conduct_cli-0.4.26}/src/conduct_cli/main.py +0 -0
- {conduct_cli-0.4.24 → conduct_cli-0.4.26}/src/conduct_cli.egg-info/SOURCES.txt +0 -0
- {conduct_cli-0.4.24 → conduct_cli-0.4.26}/src/conduct_cli.egg-info/dependency_links.txt +0 -0
- {conduct_cli-0.4.24 → conduct_cli-0.4.26}/src/conduct_cli.egg-info/entry_points.txt +0 -0
- {conduct_cli-0.4.24 → conduct_cli-0.4.26}/src/conduct_cli.egg-info/requires.txt +0 -0
- {conduct_cli-0.4.24 → conduct_cli-0.4.26}/src/conduct_cli.egg-info/top_level.txt +0 -0
|
@@ -680,6 +680,18 @@ def _install_claude_hook(hook_path: Path) -> None:
|
|
|
680
680
|
if cleaned:
|
|
681
681
|
changed = True
|
|
682
682
|
|
|
683
|
+
# Stop — auto-sync RTK + Booster savings at end of every session
|
|
684
|
+
stop = hooks.setdefault("Stop", [])
|
|
685
|
+
stop_cmd = "conduct guard sync"
|
|
686
|
+
stop_already = any(
|
|
687
|
+
stop_cmd in e.get("command", "")
|
|
688
|
+
for h in stop
|
|
689
|
+
for e in h.get("hooks", [])
|
|
690
|
+
)
|
|
691
|
+
if not stop_already:
|
|
692
|
+
stop.append({"hooks": [{"type": "command", "command": stop_cmd}]})
|
|
693
|
+
changed = True
|
|
694
|
+
|
|
683
695
|
if changed:
|
|
684
696
|
claude_settings.parent.mkdir(parents=True, exist_ok=True)
|
|
685
697
|
claude_settings.write_text(json.dumps(settings, indent=2))
|
|
@@ -687,6 +699,8 @@ def _install_claude_hook(hook_path: Path) -> None:
|
|
|
687
699
|
print(f" {GREEN}Claude Code PreToolUse hook registered{RESET}")
|
|
688
700
|
if not post_already or cleaned:
|
|
689
701
|
print(f" {GREEN}Claude Code PostToolUse hook registered{RESET}")
|
|
702
|
+
if not stop_already:
|
|
703
|
+
print(f" {GREEN}Claude Code Stop hook registered (auto-sync savings){RESET}")
|
|
690
704
|
else:
|
|
691
705
|
print(f" {GRAY}Claude Code hooks already registered{RESET}")
|
|
692
706
|
|
|
@@ -905,8 +919,11 @@ def _report_savings(cfg: dict, base_url: str, api_key: str) -> None:
|
|
|
905
919
|
}
|
|
906
920
|
|
|
907
921
|
try:
|
|
922
|
+
member_token = cfg.get("member_token", "")
|
|
908
923
|
headers = {"Content-Type": "application/json"}
|
|
909
|
-
if
|
|
924
|
+
if member_token:
|
|
925
|
+
headers["Authorization"] = f"Bearer {member_token}"
|
|
926
|
+
elif api_key:
|
|
910
927
|
headers["X-Api-Key"] = api_key
|
|
911
928
|
data = json.dumps(payload).encode()
|
|
912
929
|
req = urllib.request.Request(
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|