Add command to customize cordova internal temeletry collection (#984)
* Update cordova hostname customization support * Update requestArgs.ts * Update jsDebugConfigAdapter.ts * Gulp format * Revert gulp format * Update pathMapping hostname value * Validation argument correction * Cordova telemetry command * Add command to test list --------- Co-authored-by: Rodolfo Liberado (BEYONDSOFT CONSULTING INC) <v-rliberado@microsoft.com> Co-authored-by: Ezio Li <v-yukl@microsoft.com>
This commit is contained in:
Родитель
237cb2bffe
Коммит
247f140c96
|
@ -117,6 +117,12 @@
|
|||
"title": "Cordova: Clean",
|
||||
"category": "Cordova",
|
||||
"enablement": "!config.security.workspace.trust.enabled || isWorkspaceTrusted"
|
||||
},
|
||||
{
|
||||
"command": "cordova.telemetry",
|
||||
"title": "%cordova.telemetry%",
|
||||
"category": "Cordova",
|
||||
"enablement": "!config.security.workspace.trust.enabled || isWorkspaceTrusted"
|
||||
}
|
||||
],
|
||||
"keybindings": [
|
||||
|
|
|
@ -9,6 +9,7 @@
|
|||
"cordova.requirements": "Cordova: Requirements",
|
||||
"cordova.simulate.android": "Cordova: Simulate Android in browser",
|
||||
"cordova.simulate.ios": "Cordova: Simulate iOS in browser",
|
||||
"cordova.telemetry": "Cordova: Telemetry",
|
||||
"cordova.ionic.build": "Ionic: Build",
|
||||
"cordova.ionic.run": "Ionic: Run",
|
||||
"cordova.ionic.prepare": "Ionic: Prepare",
|
||||
|
|
|
@ -12,3 +12,4 @@ export * from "./ionicRun";
|
|||
export * from "./simulateAndroid";
|
||||
export * from "./simulateIos";
|
||||
export * from "./clean";
|
||||
export * from "./telemetry";
|
||||
|
|
|
@ -0,0 +1,17 @@
|
|||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT license. See LICENSE file in the project root for details.
|
||||
|
||||
import { window } from "vscode";
|
||||
import { CordovaCommandHelper } from "../../utils/cordovaCommandHelper";
|
||||
import { commandWrapper } from "./commandUtil";
|
||||
|
||||
export class Telemetry {
|
||||
static codeName = "cordova.telemetry";
|
||||
static createHandler = () => {
|
||||
window.showQuickPick(["On", "Off"]).then(value => {
|
||||
commandWrapper(CordovaCommandHelper.executeCordovaCommand, [
|
||||
`telemetry ${value.toLowerCase()}`,
|
||||
]);
|
||||
});
|
||||
};
|
||||
}
|
|
@ -35,6 +35,7 @@ suite("extensionContext", () => {
|
|||
"cordova.simulate.android",
|
||||
"cordova.simulate.ios",
|
||||
"cordova.clean",
|
||||
"cordova.telemetry",
|
||||
]);
|
||||
});
|
||||
});
|
||||
|
|
Загрузка…
Ссылка в новой задаче