首页 > 解决方案 > 我想减少 VSCode 中的遥测

问题描述

当 VSCode 运行时,我看到

[master *%]> ps aux | grep enableTelemetry
pl       29331  4.8  3.7 1326800 223568 ?      Sl   Mar10   2:07 /usr/share/code/code --max-old-space-size=3072 /usr/share/code/resources/app/extensions/node_modules/typescript/lib/tsserver.js --useInferredProjectPerProjectRoot --enableTelemetry --cancellationPipeName /tmp/vscode-typescript1000/a21f3a40b2e3452a6c26/tscancellation-31b196e0b1a09b5f8b22.tmp* --globalPlugins typescript-vscode-sh-plugin --pluginProbeLocations /usr/share/code/resources/app/extensions/typescript-language-features --locale en --noGetErrOnBackgroundUpdate --validateDefaultNpmLocation
pl       29366  0.2  1.4 573640 85360 ?        Sl   Mar10   0:05 /usr/share/code/code /usr/share/code/resources/app/extensions/node_modules/typescript/lib/typingsInstaller.js --globalTypingsCacheLocation /home/pl/.cache/typescript/3.8 --enableTelemetry --typesMapLocation /usr/share/code/resources/app/extensions/node_modules/typescript/lib/typesMap.json --validateDefaultNpmLocation

而 settigs 是

~/.config/Code/User/settings.json:
  32:   "telemetry.enableCrashReporter": false,
  33:   "telemetry.enableTelemetry": false,

它并没有吓到我)),只是不喜欢他们隐藏它

标签: visual-studio-code

解决方案


enableTelemetry您看到的用于 TypeScript的命令行标志并不意味着正在上传任何遥测数据,它只会使支持 VS Code 的 JS/TS IntelliSense 的 TypeScript 服务器将遥测数据发送回主 VS Code 进程。根据您的设置,然后 VS Code 本身可能会上传此遥测数据。

VS Code 或其内置扩展是否上传任何遥测数据由正常的 VS Code 遥测设置控制。尽管如此,TypeScript 服务器将始终与--enableTelemetry任何用户设置一起运行,因为该标志独立于正在上传的遥测数据。

您可以通过从源代码构建 VS Code 来检查这一点。网络监视器将显示没有从您的构建发送遥测,但--enableTelemetry仍将使用该标志


推荐阅读