feat(dsh-sdk): launcher telemetry reporting around every command

Wrap runDshSdkCommand so each command times itself and, in a finally block,
resolves consent (option A) and sends one best-effort, fire-and-forget telemetry
event (redacted cordis.yml + package.json content; never reads .env). Never
affects the command's exit code. Adds dsh-scripts -> dsh-telemetry dependency.
Default-on via absent consent entry; opt-out by a disabled telemetry entry.
The config/create wizard opt-out toggle is deferred (see design doc).
This commit is contained in:
imccyu
2026-07-17 20:28:31 +08:00
parent ca7533880e
commit 560ce3b539
7 changed files with 132 additions and 1 deletions

3
pnpm-lock.yaml generated
View File

@@ -1228,6 +1228,9 @@ importers:
'@deepseek-ai/dsh-helper':
specifier: workspace:^
version: link:../helper
'@deepseek-ai/dsh-telemetry':
specifier: workspace:^
version: link:../telemetry
commander:
specifier: ^15.0.0
version: 15.0.0