mirror of
https://github.com/ckaczor/vscode-gitlens.git
synced 2026-01-13 17:23:11 -05:00
Adds setting to explicitly control telemetry
Disables zone.js monkey patching by application insights
This commit is contained in:
@@ -305,6 +305,7 @@ GitLens is highly customizable and provides many configuration settings to allow
|
||||
|Name | Description
|
||||
|-----|------------
|
||||
|`gitlens.advanced.toggleWhitespace.enabled`|Specifies whether or not to toggle whitespace off then showing blame annotations (*may* be required by certain fonts/themes)
|
||||
|`gitlens.advanced.telemetry.enabled`|Specifies whether or not to enable GitLens telemetry (even if enabled still abides by the overall `telemetry.enableTelemetry` setting
|
||||
|`gitlens.advanced.menus`|Specifies which commands will be added to which menus
|
||||
|`gitlens.advanced.caching.enabled`|Specifies whether git output will be cached
|
||||
|`gitlens.advanced.caching.maxLines`|Specifies the threshold for caching larger documents
|
||||
|
||||
@@ -691,6 +691,11 @@
|
||||
"default": true,
|
||||
"description": "Specifies whether or not to close the QuickPick menu when focus is lost"
|
||||
},
|
||||
"gitlens.advanced.telemetry.enabled": {
|
||||
"type": "boolean",
|
||||
"default": true,
|
||||
"description": "Specifies whether or not to enable GitLens telemetry (even if enabled still abides by the overall `telemetry.enableTelemetry` setting"
|
||||
},
|
||||
"gitlens.advanced.toggleWhitespace.enabled": {
|
||||
"type": "boolean",
|
||||
"default": false,
|
||||
|
||||
@@ -98,6 +98,9 @@ export interface IAdvancedConfig {
|
||||
quickPick: {
|
||||
closeOnFocusOut: boolean;
|
||||
};
|
||||
telemetry: {
|
||||
enabled: boolean;
|
||||
};
|
||||
toggleWhitespace: {
|
||||
enabled: boolean;
|
||||
};
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
'use strict';
|
||||
import { Disposable, env, version, workspace } from 'vscode';
|
||||
import { ExtensionKey, IConfig } from './configuration';
|
||||
import * as os from 'os';
|
||||
|
||||
let _reporter: TelemetryReporter;
|
||||
@@ -7,7 +8,8 @@ let _reporter: TelemetryReporter;
|
||||
export class Telemetry extends Disposable {
|
||||
|
||||
static configure(key: string) {
|
||||
if (!workspace.getConfiguration('telemetry').get<boolean>('enableTelemetry', true)) return;
|
||||
const cfg = workspace.getConfiguration().get<IConfig>(ExtensionKey)!;
|
||||
if (!cfg.advanced.telemetry.enabled || !workspace.getConfiguration('telemetry').get<boolean>('enableTelemetry', true)) return;
|
||||
|
||||
_reporter = new TelemetryReporter(key);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user