package migration for @microsoft packages and T2 (#3046)

* package migration for @microsoft packages and T2

* Remove stale comment

* Add registerAzureUtilsExtensionVariables(ext) call before AppService

* Alphabetize

* Comments to fix loadMore if paging gets fixed
This commit is contained in:
Nathan 2022-02-15 10:08:16 -08:00 коммит произвёл GitHub
Родитель 6ab43e2268
Коммит 411ece5f94
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 4AEE18F83AFDEB23
204 изменённых файлов: 1221 добавлений и 1314 удалений

Просмотреть файл

@ -14,8 +14,8 @@
//
// The tests should import '../extension.bundle'. At design-time they live in tests/ and so will pick up this file (extension.bundle.ts).
// At runtime the tests live in dist/tests and will therefore pick up the main webpack bundle at dist/extension.bundle.js.
export * from 'vscode-azureappservice';
export * from 'vscode-azureextensionui';
export { createAzureClient, createGenericClient } from '@microsoft/vscode-azext-azureutils';
export { AzExtTreeDataProvider, DialogResponses, IActionContext, nonNullValue, parseError, registerOnActionStartHandler } from '@microsoft/vscode-azext-utils';
export * from './src/commands/addBinding/addBinding';
export * from './src/commands/copyFunctionUrl';
export * from './src/commands/createFunction/createFunction';

1732
package-lock.json сгенерированный

Разница между файлами не показана из-за своего большого размера Загрузить разницу

Просмотреть файл

@ -1104,20 +1104,23 @@
"vinyl-buffer": "^1.0.1",
"vinyl-source-stream": "^2.0.0",
"vsce": "^1.87.0",
"vscode-azureextensiondev": "^0.10.2",
"vscode-azureextensiondev": "^0.10.4",
"vscode-test": "^1.5.2",
"webpack": "^5.28.0",
"webpack-cli": "^4.6.0"
},
"dependencies": {
"@azure/arm-appinsights": "^2.1.0",
"@azure/arm-appservice": "^6.0.0",
"@azure/arm-cosmosdb": "^9.0.0",
"@azure/arm-eventhub": "^3.2.0",
"@azure/arm-servicebus": "^3.2.0",
"@azure/arm-storage": "^15.0.0",
"@azure/arm-appinsights": "^4.0.0",
"@azure/arm-appservice": "^11.0.0",
"@azure/arm-cosmosdb": "^15.0.0",
"@azure/arm-eventhub": "^5.0.0",
"@azure/arm-servicebus": "^5.0.0",
"@azure/arm-storage": "^17.0.0",
"@azure/ms-rest-js": "^2.2.1",
"@azure/storage-blob": "^12.5.0",
"@microsoft/vscode-azext-azureappservice": "^0.1.0",
"@microsoft/vscode-azext-azureutils": "^0.1.0",
"@microsoft/vscode-azext-utils": "^0.1.0",
"escape-string-regexp": "^4.0.0",
"extract-zip": "^2.0.1",
"fs-extra": "^4.0.2",
@ -1128,8 +1131,6 @@
"portfinder": "^1.0.23",
"ps-tree": "^1.1.1",
"semver": "^5.7.1",
"vscode-azureappservice": "^0.86.3",
"vscode-azureextensionui": "^0.48.5",
"vscode-azurekudu": "^0.2.0",
"vscode-nls": "^4.1.1",
"websocket": "^1.0.29",

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { IActionContext, IAzureQuickPickItem, IAzureQuickPickOptions } from 'vscode-azureextensionui';
import { IActionContext, IAzureQuickPickItem, IAzureQuickPickOptions } from '@microsoft/vscode-azext-utils';
import { localize } from './localize';
import { openUrl } from './utils/openUrl';

Просмотреть файл

@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardExecuteStep } from "@microsoft/vscode-azext-utils";
import { Progress, Uri, window, workspace } from "vscode";
import { AzureWizardExecuteStep } from "vscode-azureextensionui";
import { IFunctionBinding, IFunctionJson } from "../../funcConfig/function";
import { IBindingTemplate } from "../../templates/IBindingTemplate";
import { confirmEditJsonFile } from '../../utils/fs';

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardPromptStep, IAzureQuickPickItem } from 'vscode-azureextensionui';
import { AzureWizardPromptStep, IAzureQuickPickItem } from '@microsoft/vscode-azext-utils';
import { localize } from '../../localize';
import { IBindingWizardContext } from './IBindingWizardContext';

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardPromptStep, IAzureQuickPickItem, IWizardOptions } from 'vscode-azureextensionui';
import { AzureWizardPromptStep, IAzureQuickPickItem, IWizardOptions } from '@microsoft/vscode-azext-utils';
import { ProjectLanguage } from '../../constants';
import { ext } from '../../extensionVariables';
import { FuncVersion } from '../../FuncVersion';

Просмотреть файл

@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizard, IActionContext } from "@microsoft/vscode-azext-utils";
import { Uri, WorkspaceFolder } from "vscode";
import { AzureWizard, IActionContext } from "vscode-azureextensionui";
import { ProjectLanguage, projectTemplateKeySetting } from "../../constants";
import { ext } from "../../extensionVariables";
import { FuncVersion } from "../../FuncVersion";

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizard } from "vscode-azureextensionui";
import { AzureWizard } from "@microsoft/vscode-azext-utils";
import { localize } from "../../localize";
import { BindingCreateStep } from "./BindingCreateStep";
import { BindingDirectionStep } from "./BindingDirectionStep";

Просмотреть файл

@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardExecuteStep } from '@microsoft/vscode-azext-utils';
import { Progress } from 'vscode';
import { AzureWizardExecuteStep } from 'vscode-azureextensionui';
import { setLocalAppSetting } from '../../../funcConfig/local.settings';
import { localize } from '../../../localize';
import { IBindingSetting } from '../../../templates/IBindingTemplate';

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardPromptStep } from "vscode-azureextensionui";
import { AzureWizardPromptStep } from "@microsoft/vscode-azext-utils";
import { BindingSettingValue } from "../../../funcConfig/function";
import { IBindingSetting } from "../../../templates/IBindingTemplate";
import { getBindingSetting, setBindingSetting } from "../../createFunction/IFunctionWizardContext";

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { IAzureQuickPickItem } from "vscode-azureextensionui";
import { IAzureQuickPickItem } from "@microsoft/vscode-azext-utils";
import { BindingSettingValue } from "../../../funcConfig/function";
import { envUtils } from "../../../utils/envUtils";
import { IBindingWizardContext } from "../IBindingWizardContext";

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { IAzureQuickPickItem } from "vscode-azureextensionui";
import { IAzureQuickPickItem } from "@microsoft/vscode-azext-utils";
import { BindingSettingValue } from "../../../funcConfig/function";
import { IBindingWizardContext } from "../IBindingWizardContext";
import { BindingSettingStepBase } from "./BindingSettingStepBase";

Просмотреть файл

@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardExecuteStep } from '@microsoft/vscode-azext-utils';
import { Progress } from 'vscode';
import { AzureWizardExecuteStep } from 'vscode-azureextensionui';
import { localSettingsFileName } from '../../../constants';
import { setLocalAppSetting } from '../../../funcConfig/local.settings';
import { localize } from '../../../localize';

Просмотреть файл

@ -3,8 +3,9 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { StorageAccountKind, StorageAccountListStep, StorageAccountPerformance, StorageAccountReplication } from '@microsoft/vscode-azext-azureutils';
import { AzureWizardExecuteStep, AzureWizardPromptStep, IAzureQuickPickItem, ISubscriptionActionContext, IWizardOptions } from '@microsoft/vscode-azext-utils';
import * as path from 'path';
import { AzureWizardExecuteStep, AzureWizardPromptStep, IAzureQuickPickItem, ISubscriptionActionContext, IWizardOptions, StorageAccountKind, StorageAccountListStep, StorageAccountPerformance, StorageAccountReplication } from 'vscode-azureextensionui';
import { localSettingsFileName } from '../../../constants';
import { ext } from '../../../extensionVariables';
import { BindingSettingValue } from '../../../funcConfig/function';

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardPromptStep } from 'vscode-azureextensionui';
import { AzureWizardPromptStep } from '@microsoft/vscode-azext-utils';
import { localize } from '../../../localize';
import { IBindingWizardContext } from '../IBindingWizardContext';

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { IStorageAccountWizardContext } from 'vscode-azureextensionui';
import { IStorageAccountWizardContext } from '@microsoft/vscode-azext-azureutils';
import { getStorageConnectionString } from '../../../utils/azure';
import { IBindingWizardContext } from '../IBindingWizardContext';
import { AzureConnectionCreateStepBase, IConnection } from './AzureConnectionCreateStepBase';

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardPromptStep } from "vscode-azureextensionui";
import { AzureWizardPromptStep } from "@microsoft/vscode-azext-utils";
import { IBindingSetting, ValueType } from "../../../templates/IBindingTemplate";
import { IBindingWizardContext } from "../IBindingWizardContext";
import { BindingNameStep } from "./BindingNameStep";

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { CosmosDBManagementClient, CosmosDBManagementModels } from '@azure/arm-cosmosdb';
import { CosmosDBManagementClient, DatabaseAccountGetResults, DatabaseAccountListKeysResult } from '@azure/arm-cosmosdb';
import { getResourceGroupFromId } from '../../../../utils/azure';
import { createCosmosDBClient } from '../../../../utils/azureClients';
import { nonNullProp } from '../../../../utils/nonNull';
@ -13,14 +13,14 @@ import { ICosmosDBWizardContext } from './ICosmosDBWizardContext';
export class CosmosDBConnectionCreateStep extends AzureConnectionCreateStepBase<IBindingWizardContext & ICosmosDBWizardContext> {
public async getConnection(context: ICosmosDBWizardContext): Promise<IConnection> {
const databaseAccount: CosmosDBManagementModels.DatabaseAccountGetResults = nonNullProp(context, 'databaseAccount');
const databaseAccount: DatabaseAccountGetResults = nonNullProp(context, 'databaseAccount');
const name: string = nonNullProp(databaseAccount, 'name');
const client: CosmosDBManagementClient = await createCosmosDBClient(context);
const resourceGroup: string = getResourceGroupFromId(nonNullProp(databaseAccount, 'id'));
// NOTE: We have to generate the connection string ourselves rather than calling client.databaseAccounts.listConnectionStrings
// (The runtime currently only handles Cosmos DB connection strings _not_ mongo connection strings)
const keys: CosmosDBManagementModels.DatabaseAccountListKeysResult = await client.databaseAccounts.listKeys(resourceGroup, name);
const keys: DatabaseAccountListKeysResult = await client.databaseAccounts.listKeys(resourceGroup, name);
return {
name: name,
connectionString: `AccountEndpoint=${nonNullProp(databaseAccount, 'documentEndpoint')};AccountKey=${nonNullProp(keys, 'primaryMasterKey')};`

Просмотреть файл

@ -4,7 +4,8 @@
*--------------------------------------------------------------------------------------------*/
import { CosmosDBManagementClient } from '@azure/arm-cosmosdb';
import { AzureWizardPromptStep } from 'vscode-azureextensionui';
import { uiUtils } from '@microsoft/vscode-azext-azureutils';
import { AzureWizardPromptStep } from '@microsoft/vscode-azext-utils';
import { localize } from '../../../../localize';
import { promptForResource } from '../../../../utils/azure';
import { createCosmosDBClient } from '../../../../utils/azureClients';
@ -14,7 +15,8 @@ export class CosmosDBListStep extends AzureWizardPromptStep<ICosmosDBWizardConte
public async prompt(context: ICosmosDBWizardContext): Promise<void> {
const placeHolder: string = localize('placeHolder', 'Select a database account');
const client: CosmosDBManagementClient = await createCosmosDBClient(context);
context.databaseAccount = await promptForResource(context, placeHolder, client.databaseAccounts.list());
context.databaseAccount = await promptForResource(context, placeHolder,
uiUtils.listAllIterator(client.databaseAccounts.list()));
}
public shouldPrompt(context: ICosmosDBWizardContext): boolean {

Просмотреть файл

@ -3,9 +3,9 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { CosmosDBManagementModels } from '@azure/arm-cosmosdb';
import { ISubscriptionActionContext } from 'vscode-azureextensionui';
import { DatabaseAccountGetResults } from '@azure/arm-cosmosdb';
import { ISubscriptionActionContext } from '@microsoft/vscode-azext-utils';
export interface ICosmosDBWizardContext extends ISubscriptionActionContext {
databaseAccount?: CosmosDBManagementModels.DatabaseAccountGetResults;
databaseAccount?: DatabaseAccountGetResults;
}

Просмотреть файл

@ -3,8 +3,9 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { EventHubManagementClient, EventHubManagementModels } from '@azure/arm-eventhub';
import { AzureWizardPromptStep } from 'vscode-azureextensionui';
import { AuthorizationRule, EventHubManagementClient } from '@azure/arm-eventhub';
import { uiUtils } from '@microsoft/vscode-azext-azureutils';
import { AzureWizardPromptStep } from '@microsoft/vscode-azext-utils';
import { localize } from '../../../../localize';
import { IBaseResourceWithName, promptForResource } from '../../../../utils/azure';
import { createEventHubClient } from '../../../../utils/azureClients';
@ -22,16 +23,16 @@ export class EventHubAuthRuleListStep extends AzureWizardPromptStep<IEventHubWiz
const namespaceDescription: string = localize('namespacePolicy', '(namespace policy)');
const hubDescription: string = localize('hubPolicy', '(hub policy)');
// concats hub policies with namespace policies and adds a description to each
async function getEventHubAuthRules(): Promise<EventHubManagementModels.AuthorizationRule[]> {
const namespaceRules: EventHubManagementModels.AuthorizationRule[] = await client.namespaces.listAuthorizationRules(resourceGroupName, namespaceName);
async function getEventHubAuthRules(): Promise<AuthorizationRule[]> {
const namespaceRules: AuthorizationRule[] = await uiUtils.listAllIterator(client.namespaces.listAuthorizationRules(resourceGroupName, namespaceName));
namespaceRules.forEach((r: IBaseResourceWithName) => r._description = namespaceDescription);
const hubRules: EventHubManagementModels.AuthorizationRule[] = await client.eventHubs.listAuthorizationRules(resourceGroupName, namespaceName, eventHubName);
const hubRules: AuthorizationRule[] = await uiUtils.listAllIterator(client.eventHubs.listAuthorizationRules(resourceGroupName, namespaceName, eventHubName));
hubRules.forEach((r: IBaseResourceWithName) => r._description = hubDescription);
return hubRules.concat(namespaceRules);
}
const placeHolder: string = localize('placeHolder', 'Select an event hub policy');
const result: (EventHubManagementModels.AuthorizationRule & IBaseResourceWithName) | undefined = await promptForResource(context, placeHolder, getEventHubAuthRules());
const result: (AuthorizationRule & IBaseResourceWithName) | undefined = await promptForResource(context, placeHolder, getEventHubAuthRules());
if (result) {
context.authRuleName = nonNullProp(result, 'name');
context.isNamespaceAuthRule = result._description === namespaceDescription;

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { EventHubManagementClient, EventHubManagementModels } from '@azure/arm-eventhub';
import { AccessKeys, EventHubManagementClient } from '@azure/arm-eventhub';
import { createEventHubClient } from '../../../../utils/azureClients';
import { nonNullProp } from '../../../../utils/nonNull';
import { IBindingWizardContext } from '../../IBindingWizardContext';
@ -20,10 +20,10 @@ export class EventHubConnectionCreateStep extends AzureConnectionCreateStepBase<
const client: EventHubManagementClient = await createEventHubClient(context);
let connectionString: string;
if (context.isNamespaceAuthRule) {
const keys: EventHubManagementModels.AccessKeys = await client.namespaces.listKeys(resourceGroupName, namespaceName, authRuleName);
const keys: AccessKeys = await client.namespaces.listKeys(resourceGroupName, namespaceName, authRuleName);
connectionString = `${nonNullProp(keys, 'primaryConnectionString')};EntityPath=${eventHubName}`;
} else {
const keys: EventHubManagementModels.AccessKeys = await client.eventHubs.listKeys(resourceGroupName, namespaceName, eventHubName, authRuleName);
const keys: AccessKeys = await client.eventHubs.listKeys(resourceGroupName, namespaceName, eventHubName, authRuleName);
connectionString = nonNullProp(keys, 'primaryConnectionString');
}

Просмотреть файл

@ -3,8 +3,9 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { EventHubManagementClient, EventHubManagementModels } from '@azure/arm-eventhub';
import { AzureWizardPromptStep } from 'vscode-azureextensionui';
import { EHNamespace, EventHubManagementClient } from '@azure/arm-eventhub';
import { uiUtils } from '@microsoft/vscode-azext-azureutils';
import { AzureWizardPromptStep } from '@microsoft/vscode-azext-utils';
import { localize } from '../../../../localize';
import { promptForResource } from '../../../../utils/azure';
import { createEventHubClient } from '../../../../utils/azureClients';
@ -18,7 +19,8 @@ export class EventHubListStep extends AzureWizardPromptStep<IEventHubWizardConte
const placeHolder: string = localize('placeHolder', 'Select an event hub');
const client: EventHubManagementClient = await createEventHubClient(context);
const result: EventHubManagementModels.EHNamespace | undefined = await promptForResource(context, placeHolder, client.eventHubs.listByNamespace(resourceGroupName, namespaceName));
const result: EHNamespace | undefined = await promptForResource(context, placeHolder,
uiUtils.listAllIterator(client.eventHubs.listByNamespace(resourceGroupName, namespaceName)));
if (result) {
context.eventhubname = nonNullProp(result, 'name');
}

Просмотреть файл

@ -3,8 +3,9 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { EventHubManagementClient, EventHubManagementModels } from '@azure/arm-eventhub';
import { AzureWizardPromptStep } from 'vscode-azureextensionui';
import { EHNamespace, EventHubManagementClient } from '@azure/arm-eventhub';
import { uiUtils } from '@microsoft/vscode-azext-azureutils';
import { AzureWizardPromptStep } from '@microsoft/vscode-azext-utils';
import { localize } from '../../../../localize';
import { getResourceGroupFromId, promptForResource } from '../../../../utils/azure';
import { createEventHubClient } from '../../../../utils/azureClients';
@ -15,7 +16,8 @@ export class EventHubNamespaceListStep extends AzureWizardPromptStep<IEventHubWi
public async prompt(context: IEventHubWizardContext): Promise<void> {
const placeHolder: string = localize('placeHolder', 'Select an event hub namespace');
const client: EventHubManagementClient = await createEventHubClient(context);
const result: EventHubManagementModels.EHNamespace | undefined = await promptForResource(context, placeHolder, client.namespaces.list());
const result: EHNamespace | undefined = await promptForResource(context, placeHolder,
uiUtils.listAllIterator(client.namespaces.list()));
if (result) {
context.namespaceName = nonNullProp(result, 'name');
context.resourceGroupName = getResourceGroupFromId(nonNullProp(result, 'id'));

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { ISubscriptionActionContext } from 'vscode-azureextensionui';
import { ISubscriptionActionContext } from '@microsoft/vscode-azext-utils';
export interface IEventHubWizardContext extends ISubscriptionActionContext {
namespaceName?: string;

Просмотреть файл

@ -3,9 +3,9 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { ServiceBusManagementModels } from '@azure/arm-servicebus';
import { ISubscriptionActionContext } from 'vscode-azureextensionui';
import { SBNamespace } from '@azure/arm-servicebus';
import { ISubscriptionActionContext } from '@microsoft/vscode-azext-utils';
export interface IServiceBusWizardContext extends ISubscriptionActionContext {
sbNamespace?: ServiceBusManagementModels.SBNamespace;
sbNamespace?: SBNamespace;
}

Просмотреть файл

@ -3,7 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { ServiceBusManagementClient, ServiceBusManagementModels } from '@azure/arm-servicebus';
import { AccessKeys, SBAuthorizationRule, SBNamespace, ServiceBusManagementClient } from '@azure/arm-servicebus';
import { uiUtils } from '@microsoft/vscode-azext-azureutils';
import { localize } from '../../../../localize';
import { getResourceGroupFromId } from '../../../../utils/azure';
import { createServiceBusClient } from '../../../../utils/azureClients';
@ -14,18 +15,18 @@ import { IServiceBusWizardContext } from './IServiceBusWizardContext';
export class ServiceBusConnectionCreateStep extends AzureConnectionCreateStepBase<IServiceBusWizardContext & IBindingWizardContext> {
public async getConnection(context: IServiceBusWizardContext): Promise<IConnection> {
const sbNamespace: ServiceBusManagementModels.SBNamespace = nonNullProp(context, 'sbNamespace');
const sbNamespace: SBNamespace = nonNullProp(context, 'sbNamespace');
const id: string = nonNullProp(sbNamespace, 'id');
const name: string = nonNullProp(sbNamespace, 'name');
const resourceGroup: string = getResourceGroupFromId(id);
const client: ServiceBusManagementClient = await createServiceBusClient(context);
const authRules: ServiceBusManagementModels.SBAuthorizationRule[] = await client.namespaces.listAuthorizationRules(resourceGroup, name);
const authRule: ServiceBusManagementModels.SBAuthorizationRule | undefined = authRules.find(ar => ar.rights.some(r => r.toLowerCase() === 'listen'));
const authRules: SBAuthorizationRule[] = await uiUtils.listAllIterator(client.namespaces.listAuthorizationRules(resourceGroup, name));
const authRule: SBAuthorizationRule | undefined = authRules.find(ar => ar.rights && ar.rights.some(r => r.toLowerCase() === 'listen'));
if (!authRule) {
throw new Error(localize('noAuthRule', 'Failed to get connection string for service bus namespace "{0}".', name));
}
const keys: ServiceBusManagementModels.AccessKeys = await client.namespaces.listKeys(resourceGroup, name, nonNullProp(authRule, 'name'));
const keys: AccessKeys = await client.namespaces.listKeys(resourceGroup, name, nonNullProp(authRule, 'name'));
return {
name: name,
connectionString: nonNullProp(keys, 'primaryConnectionString')

Просмотреть файл

@ -4,7 +4,8 @@
*--------------------------------------------------------------------------------------------*/
import { ServiceBusManagementClient } from '@azure/arm-servicebus';
import { AzureWizardPromptStep } from 'vscode-azureextensionui';
import { uiUtils } from '@microsoft/vscode-azext-azureutils';
import { AzureWizardPromptStep } from '@microsoft/vscode-azext-utils';
import { localize } from '../../../../localize';
import { promptForResource } from '../../../../utils/azure';
import { createServiceBusClient } from '../../../../utils/azureClients';
@ -14,7 +15,8 @@ export class ServiceBusListStep extends AzureWizardPromptStep<IServiceBusWizardC
public async prompt(context: IServiceBusWizardContext): Promise<void> {
const placeHolder: string = localize('placeHolder', 'Select a service bus namespace');
const client: ServiceBusManagementClient = await createServiceBusClient(context);
context.sbNamespace = await promptForResource(context, placeHolder, client.namespaces.list());
context.sbNamespace = await promptForResource(context, placeHolder,
uiUtils.listAllIterator(client.namespaces.list()));
}
public shouldPrompt(context: IServiceBusWizardContext): boolean {

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { callWithTelemetryAndErrorHandling, IActionContext } from "vscode-azureextensionui";
import { callWithTelemetryAndErrorHandling, IActionContext } from "@microsoft/vscode-azext-utils";
import * as api from '../../vscode-azurefunctions.api';
import { createFunctionInternal } from "../createFunction/createFunction";

Просмотреть файл

@ -2,7 +2,7 @@
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { callWithTelemetryAndErrorHandling, IActionContext } from "vscode-azureextensionui";
import { callWithTelemetryAndErrorHandling, IActionContext } from "@microsoft/vscode-azext-utils";
import { IAppSettingsClient } from "../../vscode-azurefunctions.api";
import { downloadAppSettingsInternal } from "../appSettings/downloadAppSettings";

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzExtTreeItem, callWithTelemetryAndErrorHandling, IActionContext } from "vscode-azureextensionui";
import { AzExtTreeItem, callWithTelemetryAndErrorHandling, IActionContext } from "@microsoft/vscode-azext-utils";
import { ext } from "../../extensionVariables";
export async function revealTreeItem(resourceId: string): Promise<void> {

Просмотреть файл

@ -2,7 +2,7 @@
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { callWithTelemetryAndErrorHandling, IActionContext } from "vscode-azureextensionui";
import { callWithTelemetryAndErrorHandling, IActionContext } from "@microsoft/vscode-azext-utils";
import { IAppSettingsClient } from "../../vscode-azurefunctions.api";
import { uploadAppSettingsInternal } from "../appSettings/uploadAppSettings";

Просмотреть файл

@ -3,7 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardExecuteStep, IStorageAccountWizardContext } from 'vscode-azureextensionui';
import { IStorageAccountWizardContext } from '@microsoft/vscode-azext-azureutils';
import { AzureWizardExecuteStep } from '@microsoft/vscode-azext-utils';
import { localEmulatorConnectionString } from '../../constants';
import { azureWebJobsStorageKey, MismatchBehavior, setLocalAppSetting } from '../../funcConfig/local.settings';
import { getStorageConnectionString } from '../../utils/azure';

Просмотреть файл

@ -3,8 +3,9 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { StorageAccountKind, StorageAccountListStep, StorageAccountPerformance, StorageAccountReplication } from '@microsoft/vscode-azext-azureutils';
import { AzureWizardPromptStep, ISubscriptionActionContext, IWizardOptions } from '@microsoft/vscode-azext-utils';
import { MessageItem } from 'vscode';
import { AzureWizardPromptStep, ISubscriptionActionContext, IWizardOptions, StorageAccountKind, StorageAccountListStep, StorageAccountPerformance, StorageAccountReplication } from 'vscode-azureextensionui';
import { ext } from '../../extensionVariables';
import { localize } from '../../localize';
import { IAzureWebJobsStorageWizardContext } from './IAzureWebJobsStorageWizardContext';

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { IActionContext, ISubscriptionContext } from "vscode-azureextensionui";
import { IActionContext, ISubscriptionContext } from "@microsoft/vscode-azext-utils";
export interface IAzureWebJobsStorageWizardContext extends IActionContext, Partial<ISubscriptionContext> {
projectPath: string;

Просмотреть файл

@ -3,9 +3,9 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { IActionContext } from '@microsoft/vscode-azext-utils';
import * as path from 'path';
import { Uri } from "vscode";
import { IActionContext } from 'vscode-azureextensionui';
import { ext } from "../../extensionVariables";
import { localize } from '../../localize';
import { cpUtils } from "../../utils/cpUtils";

Просмотреть файл

@ -3,11 +3,11 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { WebSiteManagementModels } from "@azure/arm-appservice";
import { StringDictionary } from "@azure/arm-appservice";
import { AppSettingsTreeItem, confirmOverwriteSettings, IAppSettingsClient } from "@microsoft/vscode-azext-azureappservice";
import { IActionContext } from "@microsoft/vscode-azext-utils";
import * as fse from 'fs-extra';
import * as vscode from 'vscode';
import { AppSettingsTreeItem, confirmOverwriteSettings, IAppSettingsClient } from "vscode-azureappservice";
import { IActionContext } from "vscode-azureextensionui";
import { localSettingsFileName, viewOutput } from "../../constants";
import { ext } from "../../extensionVariables";
import { getLocalSettingsJson, ILocalSettingsJson } from "../../funcConfig/local.settings";
@ -46,7 +46,7 @@ export async function downloadAppSettingsInternal(context: IActionContext, clien
localSettings.Values = {};
}
const remoteSettings: WebSiteManagementModels.StringDictionary = await client.listApplicationSettings();
const remoteSettings: StringDictionary = await client.listApplicationSettings();
ext.outputChannel.appendLog(localize('downloadingSettings', 'Downloading settings...'), { resourceName: client.fullName });
if (remoteSettings.properties) {

Просмотреть файл

@ -3,9 +3,9 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { IActionContext } from '@microsoft/vscode-azext-utils';
import * as path from 'path';
import { Uri } from "vscode";
import { IActionContext } from 'vscode-azureextensionui';
import { ext } from "../../extensionVariables";
import { localize } from '../../localize';
import { cpUtils } from "../../utils/cpUtils";

Просмотреть файл

@ -3,10 +3,10 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { IActionContext } from '@microsoft/vscode-azext-utils';
import * as fse from 'fs-extra';
import * as path from 'path';
import { workspace, WorkspaceFolder } from "vscode";
import { IActionContext } from 'vscode-azureextensionui';
import { localSettingsFileName } from "../../constants";
import { selectWorkspaceFile } from "../../utils/workspace";
import { tryGetFunctionProjectRoot } from "../createNewProject/verifyIsProject";

Просмотреть файл

@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizard, IActionContext } from '@microsoft/vscode-azext-utils';
import * as path from 'path';
import { AzureWizard, IActionContext } from 'vscode-azureextensionui';
import { localize } from '../../localize';
import { AzureWebJobsStorageExecuteStep } from './AzureWebJobsStorageExecuteStep';
import { AzureWebJobsStoragePromptStep } from './AzureWebJobsStoragePromptStep';

Просмотреть файл

@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AppSettingTreeItem } from "vscode-azureappservice";
import { IActionContext } from "vscode-azureextensionui";
import { AppSettingTreeItem } from "@microsoft/vscode-azext-azureappservice";
import { IActionContext } from "@microsoft/vscode-azext-utils";
import { ext } from "../../extensionVariables";
export async function toggleSlotSetting(context: IActionContext, node?: AppSettingTreeItem): Promise<void> {

Просмотреть файл

@ -3,11 +3,11 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { WebSiteManagementModels } from "@azure/arm-appservice";
import { StringDictionary } from "@azure/arm-appservice";
import { AppSettingsTreeItem, confirmOverwriteSettings, IAppSettingsClient } from "@microsoft/vscode-azext-azureappservice";
import { IActionContext } from "@microsoft/vscode-azext-utils";
import * as fse from 'fs-extra';
import * as vscode from 'vscode';
import { AppSettingsTreeItem, confirmOverwriteSettings, IAppSettingsClient } from "vscode-azureappservice";
import { IActionContext } from "vscode-azureextensionui";
import { localSettingsFileName, viewOutput } from "../../constants";
import { ext } from "../../extensionVariables";
import { ILocalSettingsJson } from "../../funcConfig/local.settings";
@ -45,7 +45,7 @@ export async function uploadAppSettingsInternal(context: IActionContext, client:
}
if (localSettings.Values) {
const remoteSettings: WebSiteManagementModels.StringDictionary = await client.listApplicationSettings();
const remoteSettings: StringDictionary = await client.listApplicationSettings();
if (!remoteSettings.properties) {
remoteSettings.properties = {};
}

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { IActionContext } from 'vscode-azureextensionui';
import { IActionContext } from '@microsoft/vscode-azext-utils';
import { ext } from '../extensionVariables';
import { ProductionSlotTreeItem } from '../tree/ProductionSlotTreeItem';
import { SlotTreeItemBase } from '../tree/SlotTreeItemBase';

Просмотреть файл

@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { editScmType } from 'vscode-azureappservice';
import { IActionContext } from 'vscode-azureextensionui';
import { editScmType } from '@microsoft/vscode-azext-azureappservice';
import { IActionContext } from '@microsoft/vscode-azext-utils';
import { ext } from '../extensionVariables';
import { ProductionSlotTreeItem } from '../tree/ProductionSlotTreeItem';
import { SlotTreeItemBase } from '../tree/SlotTreeItemBase';

Просмотреть файл

@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { IActionContext } from '@microsoft/vscode-azext-utils';
import * as vscode from 'vscode';
import { IActionContext } from 'vscode-azureextensionui';
import { ext } from '../extensionVariables';
import { localize } from '../localize';
import { FunctionTreeItemBase } from '../tree/FunctionTreeItemBase';

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzExtParentTreeItem, IActionContext } from 'vscode-azureextensionui';
import { AzExtParentTreeItem, IActionContext } from '@microsoft/vscode-azext-utils';
import { ext } from '../extensionVariables';
export async function createChildNode(context: IActionContext, expectedContextValue: string | RegExp, node?: AzExtParentTreeItem): Promise<void> {

Просмотреть файл

@ -3,9 +3,9 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardExecuteStep, callWithTelemetryAndErrorHandling, IActionContext } from '@microsoft/vscode-azext-utils';
import * as fse from 'fs-extra';
import { Progress, Uri, window, workspace } from 'vscode';
import { AzureWizardExecuteStep, callWithTelemetryAndErrorHandling, IActionContext } from 'vscode-azureextensionui';
import { ext } from '../../extensionVariables';
import { localize } from '../../localize';
import { IFunctionTemplate } from '../../templates/IFunctionTemplate';

Просмотреть файл

@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardExecuteStep, AzureWizardPromptStep, IActionContext, IAzureQuickPickItem, IAzureQuickPickOptions, IWizardOptions } from '@microsoft/vscode-azext-utils';
import * as escape from 'escape-string-regexp';
import { AzureWizardExecuteStep, AzureWizardPromptStep, IActionContext, IAzureQuickPickItem, IAzureQuickPickOptions, IWizardOptions } from 'vscode-azureextensionui';
import { JavaBuildTool, ProjectLanguage, TemplateFilter, templateFilterSetting } from '../../constants';
import { canValidateAzureWebJobStorageOnDebug } from '../../debug/validatePreDebug';
import { ext } from '../../extensionVariables';

Просмотреть файл

@ -3,9 +3,9 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardPromptStep } from '@microsoft/vscode-azext-utils';
import * as fse from 'fs-extra';
import * as path from 'path';
import { AzureWizardPromptStep } from 'vscode-azureextensionui';
import { localize } from '../../localize';
import { IFunctionTemplate } from '../../templates/IFunctionTemplate';
import { nonNullProp } from '../../utils/nonNull';

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { ISubscriptionContext } from "vscode-azureextensionui";
import { ISubscriptionContext } from "@microsoft/vscode-azext-utils";
import { BindingSettingValue } from "../../funcConfig/function";
import { IBindingSetting } from "../../templates/IBindingTemplate";
import { IFunctionTemplate } from "../../templates/IFunctionTemplate";

Просмотреть файл

@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizard, IActionContext, UserCancelledError } from '@microsoft/vscode-azext-utils';
import { commands, MessageItem, Uri, window, workspace, WorkspaceFolder } from 'vscode';
import { AzureWizard, IActionContext, UserCancelledError } from 'vscode-azureextensionui';
import { ProjectLanguage, projectTemplateKeySetting } from '../../constants';
import { NoWorkspaceError } from '../../errors';
import { addLocalFuncTelemetry } from '../../funcCoreTools/getLocalFuncCoreToolsVersion';

Просмотреть файл

@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { IActionContext } from '@microsoft/vscode-azext-utils';
import * as path from 'path';
import { IActionContext } from 'vscode-azureextensionui';
import { ext } from '../../../extensionVariables';
import { FuncVersion } from '../../../FuncVersion';
import { executeDotnetTemplateCommand, validateDotnetInstalled } from '../../../templates/dotnet/executeDotnetTemplateCommand';

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardPromptStep } from 'vscode-azureextensionui';
import { AzureWizardPromptStep } from '@microsoft/vscode-azext-utils';
import * as XRegExp from 'xregexp';
import { localize } from "../../../localize";
import { IDotnetFunctionWizardContext } from './IDotnetFunctionWizardContext';

Просмотреть файл

@ -3,9 +3,9 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardExecuteStep, DialogResponses, IActionContext } from '@microsoft/vscode-azext-utils';
import * as path from 'path';
import { ProgressLocation, Uri, window } from "vscode";
import { AzureWizardExecuteStep, DialogResponses, IActionContext } from 'vscode-azureextensionui';
import { ProjectLanguage } from "../../../constants";
import { ext } from "../../../extensionVariables";
import { localize } from "../../../localize";

Просмотреть файл

@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardPromptStep } from "@microsoft/vscode-azext-utils";
import { OpenDialogOptions, Uri, workspace } from "vscode";
import { AzureWizardPromptStep } from "vscode-azureextensionui";
import { IFunctionWizardContext } from "../IFunctionWizardContext";
export class OpenAPIGetSpecificationFileStep extends AzureWizardPromptStep<IFunctionWizardContext> {

Просмотреть файл

@ -3,10 +3,11 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { WebSiteManagementClient, WebSiteManagementMappers, WebSiteManagementModels as SiteModels, WebSiteManagementModels } from '@azure/arm-appservice';
import { NameValuePair, Site, SiteConfig, WebSiteManagementClient } from '@azure/arm-appservice';
import { CustomLocation, IAppServiceWizardContext, ParsedSite, WebsiteOS } from '@microsoft/vscode-azext-azureappservice';
import { LocationListStep } from '@microsoft/vscode-azext-azureutils';
import { AzureWizardExecuteStep, parseError } from '@microsoft/vscode-azext-utils';
import { Progress } from 'vscode';
import { CustomLocation, IAppServiceWizardContext, ParsedSite, WebsiteOS } from 'vscode-azureappservice';
import { AzureWizardExecuteStep, LocationListStep, parseError } from 'vscode-azureextensionui';
import { contentConnectionStringKey, contentShareKey, extensionVersionKey, ProjectLanguage, runFromPackageKey, webProvider } from '../../constants';
import { ext } from '../../extensionVariables';
import { azureWebJobsStorageKey } from '../../funcConfig/local.settings';
@ -42,7 +43,7 @@ export class FunctionAppCreateStep extends AzureWizardExecuteStep<IFunctionAppWi
const rgName: string = nonNullProp(nonNullProp(context, 'resourceGroup'), 'name');
const client: WebSiteManagementClient = await createWebSiteClient(context);
context.site = await client.webApps.createOrUpdate(rgName, siteName, await this.getNewSite(context, stack));
context.site = await client.webApps.beginCreateOrUpdateAndWait(rgName, siteName, await this.getNewSite(context, stack));
const site = new ParsedSite(context.site, context);
if (!site.isLinux) { // not supported on linux
@ -61,9 +62,9 @@ export class FunctionAppCreateStep extends AzureWizardExecuteStep<IFunctionAppWi
return !context.site;
}
private async getNewSite(context: IFunctionAppWizardContext, stack: FullFunctionAppStack): Promise<WebSiteManagementModels.Site> {
private async getNewSite(context: IFunctionAppWizardContext, stack: FullFunctionAppStack): Promise<Site> {
const location = await LocationListStep.getLocation(context, webProvider);
const site: WebSiteManagementModels.Site = {
const site: Site = {
name: context.newSiteName,
kind: getSiteKind(context),
location: nonNullProp(location, 'name'),
@ -80,49 +81,22 @@ export class FunctionAppCreateStep extends AzureWizardExecuteStep<IFunctionAppWi
return site;
}
/**
* Has a few temporary workarounds so that the sdk allows some newer properties on the plan
*/
private addCustomLocationProperties(site: WebSiteManagementModels.Site, customLocation: CustomLocation): void {
private addCustomLocationProperties(site: Site, customLocation: CustomLocation): void {
nonNullProp(site, 'siteConfig').alwaysOn = true;
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
WebSiteManagementMappers.Site.type.modelProperties!.extendedLocation = {
serializedName: 'extendedLocation',
type: {
name: "Composite",
modelProperties: {
name: {
serializedName: "name",
type: {
name: "String"
}
},
type: {
serializedName: "type",
type: {
name: "String"
}
}
}
}
};
// eslint-disable-next-line @typescript-eslint/no-unsafe-member-access, @typescript-eslint/no-explicit-any
(<any>site).extendedLocation = { name: customLocation.id, type: 'customLocation' };
site.extendedLocation = { name: customLocation.id, type: 'customLocation' };
}
private async getNewSiteConfig(context: IFunctionAppWizardContext, stack: FullFunctionAppStack): Promise<SiteModels.SiteConfig> {
private async getNewSiteConfig(context: IFunctionAppWizardContext, stack: FullFunctionAppStack): Promise<SiteConfig> {
const stackSettings: FunctionAppRuntimeSettings = nonNullProp(stack.minorVersion.stackSettings, context.newSiteOS === WebsiteOS.linux ? 'linuxRuntimeSettings' : 'windowsRuntimeSettings');
// https://github.com/microsoft/vscode-azurefunctions/issues/2990
if (context.newSiteOS === 'windows' && context.version === FuncVersion.v4) {
stackSettings.siteConfigPropertiesDictionary.netFrameworkVersion = 'v6.0'
}
const newSiteConfig: SiteModels.SiteConfig = stackSettings.siteConfigPropertiesDictionary;
const newSiteConfig: SiteConfig = stackSettings.siteConfigPropertiesDictionary;
const storageConnectionString: string = (await getStorageConnectionString(context)).connectionString;
const appSettings: SiteModels.NameValuePair[] = [
const appSettings: NameValuePair[] = [
{
name: azureWebJobsStorageKey,
value: storageConnectionString

Просмотреть файл

@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AppServicePlanListStep, IAppServiceWizardContext, setLocationsTask } from 'vscode-azureappservice';
import { AzureWizardPromptStep, IAzureQuickPickItem, IWizardOptions } from 'vscode-azureextensionui';
import { AppServicePlanListStep, IAppServiceWizardContext, setLocationsTask } from '@microsoft/vscode-azext-azureappservice';
import { AzureWizardPromptStep, IAzureQuickPickItem, IWizardOptions } from '@microsoft/vscode-azext-utils';
import { localize } from '../../localize';
import { getRandomHexString } from '../../utils/fs';
import { nonNullProp } from '../../utils/nonNull';

Просмотреть файл

@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { IAppServiceWizardContext } from 'vscode-azureappservice';
import { ICreateChildImplContext } from 'vscode-azureextensionui';
import { IAppServiceWizardContext } from '@microsoft/vscode-azext-azureappservice';
import { ICreateChildImplContext } from '@microsoft/vscode-azext-utils';
import { FuncVersion } from '../../FuncVersion';
import { AppStackMajorVersion, AppStackMinorVersion } from './stacks/models/AppStackModel';
import { FunctionAppRuntimes, FunctionAppStack } from './stacks/models/FunctionAppStackModel';

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzExtParentTreeItem, IActionContext } from 'vscode-azureextensionui';
import { AzExtParentTreeItem, IActionContext } from '@microsoft/vscode-azext-utils';
import { ext } from '../../extensionVariables';
import { localize } from '../../localize';
import { ProductionSlotTreeItem } from '../../tree/ProductionSlotTreeItem';

Просмотреть файл

@ -3,9 +3,9 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { ParsedSite } from '@microsoft/vscode-azext-azureappservice';
import { IActionContext } from '@microsoft/vscode-azext-utils';
import { window } from 'vscode';
import { ParsedSite } from 'vscode-azureappservice';
import { IActionContext } from 'vscode-azureextensionui';
import { viewOutput } from '../../constants';
import { ext } from '../../extensionVariables';
import { localize } from '../../localize';

Просмотреть файл

@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { setLocationsTask, SiteOSStep, WebsiteOS } from 'vscode-azureappservice';
import { AzureWizardPromptStep, IAzureQuickPickItem, IWizardOptions } from 'vscode-azureextensionui';
import { setLocationsTask, SiteOSStep, WebsiteOS } from '@microsoft/vscode-azext-azureappservice';
import { AzureWizardPromptStep, IAzureQuickPickItem, IWizardOptions } from '@microsoft/vscode-azext-utils';
import { getMajorVersion, promptForFuncVersion } from '../../../FuncVersion';
import { localize } from '../../../localize';
import { FullFunctionAppStack, IFunctionAppWizardContext } from '../IFunctionAppWizardContext';

Просмотреть файл

@ -4,7 +4,8 @@
*--------------------------------------------------------------------------------------------*/
import { HttpOperationResponse, ServiceClient } from '@azure/ms-rest-js';
import { createGenericClient, IAzureQuickPickItem, parseError } from 'vscode-azureextensionui';
import { createGenericClient } from '@microsoft/vscode-azext-azureutils';
import { IAzureQuickPickItem, parseError } from '@microsoft/vscode-azext-utils';
import { hiddenStacksSetting } from '../../../constants';
import { FuncVersion } from '../../../FuncVersion';
import { localize } from '../../../localize';

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardPromptStep } from 'vscode-azureextensionui';
import { AzureWizardPromptStep } from '@microsoft/vscode-azext-utils';
import { localize } from '../../localize';
import { getContainingWorkspace, selectWorkspaceFolder } from '../../utils/workspace';
import { IProjectWizardContext } from './IProjectWizardContext';

Просмотреть файл

@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { IActionContext } from "@microsoft/vscode-azext-utils";
import { Uri, WorkspaceFolder } from "vscode";
import { IActionContext } from "vscode-azureextensionui";
import { ProjectLanguage } from "../../constants";
import { FuncVersion } from "../../FuncVersion";
import { cliFeedUtils } from "../../utils/cliFeedUtils";

Просмотреть файл

@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardExecuteStep, AzureWizardPromptStep, IAzureQuickPickItem, IWizardOptions, UserCancelledError } from '@microsoft/vscode-azext-utils';
import { QuickPickOptions } from 'vscode';
import { AzureWizardExecuteStep, AzureWizardPromptStep, IAzureQuickPickItem, IWizardOptions, UserCancelledError } from 'vscode-azureextensionui';
import { ProjectLanguage } from '../../constants';
import { localize } from '../../localize';
import { nonNullProp } from '../../utils/nonNull';

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardPromptStep, IAzureQuickPickItem } from 'vscode-azureextensionui';
import { AzureWizardPromptStep, IAzureQuickPickItem } from '@microsoft/vscode-azext-utils';
import { localize } from '../../localize';
import { IProjectWizardContext, OpenBehavior } from './IProjectWizardContext';

Просмотреть файл

@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardExecuteStep } from '@microsoft/vscode-azext-utils';
import { commands, Uri, workspace, WorkspaceFolder } from 'vscode';
import { AzureWizardExecuteStep } from 'vscode-azureextensionui';
import { IProjectWizardContext } from './IProjectWizardContext';
export class OpenFolderStep extends AzureWizardExecuteStep<IProjectWizardContext> {

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { IActionContext } from 'vscode-azureextensionui';
import { IActionContext } from '@microsoft/vscode-azext-utils';
import { IHostJsonV2 } from '../../../funcConfig/host';
import { ScriptProjectCreateStep } from './ScriptProjectCreateStep';

Просмотреть файл

@ -3,9 +3,9 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { DialogResponses, IActionContext } from '@microsoft/vscode-azext-utils';
import * as fse from 'fs-extra';
import * as path from 'path';
import { DialogResponses, IActionContext } from 'vscode-azureextensionui';
import { gitignoreFileName, hostFileName, localSettingsFileName, ProjectLanguage } from '../../../constants';
import { azureWebJobsStorageKey, MismatchBehavior, setLocalAppSetting } from '../../../funcConfig/local.settings';
import { FuncVersion, getMajorVersion } from '../../../FuncVersion';

Просмотреть файл

@ -3,10 +3,10 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { IActionContext } from "@microsoft/vscode-azext-utils";
import * as fse from 'fs-extra';
import * as path from 'path';
import { Progress } from 'vscode';
import { IActionContext } from 'vscode-azureextensionui';
import { buildGradleFileName, JavaBuildTool, settingsGradleFileName } from '../../../constants';
import { localize } from '../../../localize';
import { confirmOverwriteFile } from '../../../utils/fs';

Просмотреть файл

@ -3,10 +3,10 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { IActionContext } from '@microsoft/vscode-azext-utils';
import * as fse from 'fs-extra';
import * as os from 'os';
import * as path from 'path';
import { IActionContext } from 'vscode-azureextensionui';
import { JavaBuildTool } from '../../../constants';
import { ext } from '../../../extensionVariables';
import * as fsUtil from '../../../utils/fs';

Просмотреть файл

@ -4,10 +4,10 @@
*--------------------------------------------------------------------------------------------*/
import { HttpOperationResponse } from '@azure/ms-rest-js';
import { IActionContext } from '@microsoft/vscode-azext-utils';
import * as fse from 'fs-extra';
import * as path from 'path';
import { Progress } from 'vscode';
import { IActionContext } from 'vscode-azureextensionui';
import { workerRuntimeVersionKey } from '../../../constants';
import { IHostJsonV2 } from '../../../funcConfig/host';
import { hasMinFuncCliVersion } from '../../../funcCoreTools/hasMinFuncCliVersion';

Просмотреть файл

@ -3,9 +3,9 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardExecuteStep, callWithTelemetryAndErrorHandling, IActionContext } from '@microsoft/vscode-azext-utils';
import * as fse from 'fs-extra';
import { Progress } from 'vscode';
import { AzureWizardExecuteStep, callWithTelemetryAndErrorHandling, IActionContext } from 'vscode-azureextensionui';
import { localize } from '../../../localize';
import { gitUtils } from '../../../utils/gitUtils';
import { IProjectWizardContext } from '../IProjectWizardContext';

Просмотреть файл

@ -3,11 +3,11 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { IActionContext } from '@microsoft/vscode-azext-utils';
import * as fse from 'fs-extra';
import * as os from 'os';
import * as path from 'path';
import { Progress } from 'vscode';
import { IActionContext } from 'vscode-azureextensionui';
import { gitignoreFileName, hostFileName, localSettingsFileName, workerRuntimeKey } from '../../../constants';
import { IHostJsonV1, IHostJsonV2 } from '../../../funcConfig/host';
import { ILocalSettingsJson } from '../../../funcConfig/local.settings';

Просмотреть файл

@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizard, IActionContext } from '@microsoft/vscode-azext-utils';
import { window } from 'vscode';
import { AzureWizard, IActionContext } from 'vscode-azureextensionui';
import { funcVersionSetting, ProjectLanguage, projectLanguageSetting, projectOpenBehaviorSetting, projectTemplateKeySetting } from '../../constants';
import { addLocalFuncTelemetry } from '../../funcCoreTools/getLocalFuncCoreToolsVersion';
import { tryGetLocalFuncVersion } from '../../funcCoreTools/tryGetLocalFuncVersion';

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardPromptStep, IAzureQuickPickItem } from "vscode-azureextensionui";
import { AzureWizardPromptStep, IAzureQuickPickItem } from "@microsoft/vscode-azext-utils";
import { hiddenStacksSetting } from "../../../constants";
import { promptForFuncVersion } from "../../../FuncVersion";
import { localize } from "../../../localize";

Просмотреть файл

@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardPromptStep } from "@microsoft/vscode-azext-utils";
import { InputBoxOptions } from "vscode";
import { AzureWizardPromptStep } from "vscode-azureextensionui";
import { localize } from "../../../localize";
import { nonNullProp } from "../../../utils/nonNull";
import { IJavaProjectWizardContext } from "./IJavaProjectWizardContext";

Просмотреть файл

@ -3,9 +3,9 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardPromptStep } from "@microsoft/vscode-azext-utils";
import * as path from 'path';
import { InputBoxOptions } from "vscode";
import { AzureWizardPromptStep } from "vscode-azureextensionui";
import { localize } from "../../../localize";
import { IJavaProjectWizardContext, validateMavenIdentifier } from "./IJavaProjectWizardContext";

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardPromptStep, IAzureQuickPickItem } from "vscode-azureextensionui";
import { AzureWizardPromptStep, IAzureQuickPickItem } from "@microsoft/vscode-azext-utils";
import { JavaBuildTool, previewDescription } from "../../../constants";
import { localize } from "../../../localize";
import { IJavaProjectWizardContext } from "./IJavaProjectWizardContext";

Просмотреть файл

@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardPromptStep } from "@microsoft/vscode-azext-utils";
import { InputBoxOptions } from "vscode";
import { AzureWizardPromptStep } from "vscode-azureextensionui";
import { localize } from "../../../localize";
import { IJavaProjectWizardContext, validateMavenIdentifier } from "./IJavaProjectWizardContext";

Просмотреть файл

@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardPromptStep } from "@microsoft/vscode-azext-utils";
import { InputBoxOptions } from "vscode";
import { AzureWizardPromptStep } from "vscode-azureextensionui";
import { localize } from "../../../localize";
import { IJavaProjectWizardContext } from "./IJavaProjectWizardContext";

Просмотреть файл

@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardPromptStep } from "@microsoft/vscode-azext-utils";
import { InputBoxOptions } from "vscode";
import { AzureWizardPromptStep } from "vscode-azureextensionui";
import { localize } from "../../../localize";
import { IJavaProjectWizardContext } from "./IJavaProjectWizardContext";

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardPromptStep, IAzureQuickPickItem } from "vscode-azureextensionui";
import { AzureWizardPromptStep, IAzureQuickPickItem } from "@microsoft/vscode-azext-utils";
import { hasMinFuncCliVersion } from "../../../funcCoreTools/hasMinFuncCliVersion";
import { localize } from "../../../localize";
import { IJavaProjectWizardContext } from "./IJavaProjectWizardContext";

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardExecuteStep, AzureWizardPromptStep } from "vscode-azureextensionui";
import { AzureWizardExecuteStep, AzureWizardPromptStep } from "@microsoft/vscode-azext-utils";
import { IProjectWizardContext } from "../IProjectWizardContext";
import { GradleProjectCreateStep } from "../ProjectCreateStep/GradleProjectCreateSteps";
import { MavenProjectCreateStep } from "../ProjectCreateStep/MavenProjectCreateSteps";

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardPromptStep, parseError } from "vscode-azureextensionui";
import { AzureWizardPromptStep, parseError } from "@microsoft/vscode-azext-utils";
import { localize } from "../../../localize";
import { IPythonVenvWizardContext } from "./IPythonVenvWizardContext";
import { getPythonVersion, getSupportedPythonVersions, isSupportedPythonVersion } from './pythonVersion';

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { IActionContext } from "vscode-azureextensionui";
import { IActionContext } from "@microsoft/vscode-azext-utils";
import { FuncVersion } from "../../../FuncVersion";
export interface IPythonVenvWizardContext extends IActionContext {

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardPromptStep, IAzureQuickPickItem, IWizardOptions } from "vscode-azureextensionui";
import { AzureWizardPromptStep, IAzureQuickPickItem, IWizardOptions } from "@microsoft/vscode-azext-utils";
import { localize } from "../../../localize";
import { getGlobalSetting } from "../../../vsCodeConfig/settings";
import { EnterPythonAliasStep } from "./EnterPythonAliasStep";

Просмотреть файл

@ -3,10 +3,10 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzureWizardExecuteStep } from '@microsoft/vscode-azext-utils';
import * as fse from 'fs-extra';
import * as path from 'path';
import { Progress } from 'vscode';
import { AzureWizardExecuteStep } from 'vscode-azureextensionui';
import { requirementsFileName } from '../../../constants';
import { ext } from '../../../extensionVariables';
import { localize } from "../../../localize";

Просмотреть файл

@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { IActionContext } from '@microsoft/vscode-azext-utils';
import * as semver from 'semver';
import { IActionContext } from 'vscode-azureextensionui';
import { ext } from '../../../extensionVariables';
import { getLocalFuncCoreToolsVersion } from '../../../funcCoreTools/getLocalFuncCoreToolsVersion';
import { FuncVersion, getMajorVersion } from '../../../FuncVersion';

Просмотреть файл

@ -3,10 +3,10 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { DialogResponses, IActionContext, IAzureQuickPickItem } from '@microsoft/vscode-azext-utils';
import * as fse from 'fs-extra';
import * as path from 'path';
import { MessageItem, WorkspaceFolder } from 'vscode';
import { DialogResponses, IActionContext, IAzureQuickPickItem } from 'vscode-azureextensionui';
import { hostFileName, projectSubpathSetting } from '../../constants';
import { localize } from '../../localize';
import { telemetryUtils } from '../../utils/telemetryUtils';

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { IActionContext } from 'vscode-azureextensionui';
import { IActionContext } from '@microsoft/vscode-azext-utils';
import { ext } from '../extensionVariables';
import { SlotsTreeItem } from '../tree/SlotsTreeItem';
import { SlotTreeItem } from '../tree/SlotTreeItem';

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzExtTreeItem, IActionContext, ITreeItemPickerContext } from 'vscode-azureextensionui';
import { AzExtTreeItem, IActionContext, ITreeItemPickerContext } from '@microsoft/vscode-azext-utils';
import { localize } from '../localize';
import { deleteNode } from './deleteNode';

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzExtTreeItem, IActionContext } from 'vscode-azureextensionui';
import { AzExtTreeItem, IActionContext } from '@microsoft/vscode-azext-utils';
import { ProductionSlotTreeItem } from '../tree/ProductionSlotTreeItem';
import { deleteNode } from './deleteNode';

Просмотреть файл

@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzExtTreeItem, IActionContext } from 'vscode-azureextensionui';
import { AzExtTreeItem, IActionContext } from '@microsoft/vscode-azext-utils';
import { ext } from '../extensionVariables';
export async function deleteNode(context: IActionContext, expectedContextValue: string | RegExp, node?: AzExtTreeItem): Promise<void> {

Просмотреть файл

@ -3,10 +3,10 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { WebSiteManagementModels } from '@azure/arm-appservice';
import { SiteConfigResource } from '@azure/arm-appservice';
import { deploy as innerDeploy, getDeployFsPath, getDeployNode, IDeployContext, IDeployPaths, showDeployConfirmation } from '@microsoft/vscode-azext-azureappservice';
import { DialogResponses, IActionContext } from '@microsoft/vscode-azext-utils';
import * as vscode from 'vscode';
import { deploy as innerDeploy, getDeployFsPath, getDeployNode, IDeployContext, IDeployPaths, showDeployConfirmation } from 'vscode-azureappservice';
import { DialogResponses, IActionContext } from 'vscode-azureextensionui';
import { deploySubpathSetting, ProjectLanguage, remoteBuildSetting, ScmType } from '../../constants';
import { ext } from '../../extensionVariables';
import { addLocalFuncTelemetry } from '../../funcCoreTools/getLocalFuncCoreToolsVersion';
@ -51,7 +51,7 @@ async function deploy(actionContext: IActionContext, arg1: vscode.Uri | string |
}
const client = await node.site.createClient(actionContext);
const siteConfig: WebSiteManagementModels.SiteConfigResource = await client.getSiteConfig();
const siteConfig: SiteConfigResource = await client.getSiteConfig();
const isConsumption: boolean = await client.getIsConsumption(actionContext);
let isZipDeploy: boolean = siteConfig.scmType !== ScmType.LocalGit && siteConfig.scmType !== ScmType.GitHub;
if (!isZipDeploy && node.site.isLinux && isConsumption) {
@ -113,7 +113,7 @@ async function deploy(actionContext: IActionContext, arg1: vscode.Uri | string |
await notifyDeployComplete(context, node, context.workspaceFolder);
}
async function updateWorkerProcessTo64BitIfRequired(context: IDeployContext, siteConfig: WebSiteManagementModels.SiteConfigResource, node: SlotTreeItemBase, language: ProjectLanguage): Promise<void> {
async function updateWorkerProcessTo64BitIfRequired(context: IDeployContext, siteConfig: SiteConfigResource, node: SlotTreeItemBase, language: ProjectLanguage): Promise<void> {
const functionProject: string | undefined = await tryGetFunctionProjectRoot(context, context.workspaceFolder);
if (functionProject === undefined) {
return;
@ -130,7 +130,7 @@ async function updateWorkerProcessTo64BitIfRequired(context: IDeployContext, sit
if (dialogResult === deployAnyway) {
return;
}
const config: WebSiteManagementModels.SiteConfigResource = {
const config: SiteConfigResource = {
use32BitWorkerProcess: false
};
const client = await node.site.createClient(context);

Просмотреть файл

@ -3,9 +3,9 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { AzExtTreeItem, callWithTelemetryAndErrorHandling, IActionContext } from '@microsoft/vscode-azext-utils';
import * as retry from 'p-retry';
import { MessageItem, window, WorkspaceFolder } from 'vscode';
import { AzExtTreeItem, callWithTelemetryAndErrorHandling, IActionContext } from 'vscode-azureextensionui';
import { ext } from '../../extensionVariables';
import { localize } from '../../localize';
import { RemoteFunctionsTreeItem } from '../../tree/remoteProject/RemoteFunctionsTreeItem';

Просмотреть файл

@ -3,9 +3,9 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { handleFailedPreDeployTask, IDeployContext, IPreDeployTaskResult, tryRunPreDeployTask } from '@microsoft/vscode-azext-azureappservice';
import { DialogResponses, UserCancelledError } from '@microsoft/vscode-azext-utils';
import * as vscode from 'vscode';
import { handleFailedPreDeployTask, IDeployContext, IPreDeployTaskResult, tryRunPreDeployTask } from 'vscode-azureappservice';
import { DialogResponses, UserCancelledError } from 'vscode-azureextensionui';
import { buildNativeDeps, packTaskName, preDeployTaskSetting, tasksFileName } from '../../constants';
import { ext } from '../../extensionVariables';
import { validateFuncCoreToolsInstalled } from '../../funcCoreTools/validateFuncCoreToolsInstalled';

Просмотреть файл

@ -3,9 +3,9 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { IDeployContext, ParsedSite } from '@microsoft/vscode-azext-azureappservice';
import * as path from 'path';
import * as vscode from 'vscode';
import { IDeployContext, ParsedSite } from 'vscode-azureappservice';
import { deploySubpathSetting, packTaskName, preDeployTaskSetting, ProjectLanguage, remoteBuildSetting } from '../../constants';
import { localize } from '../../localize';
import { updateWorkspaceSetting } from '../../vsCodeConfig/settings';

Просмотреть файл

@ -3,10 +3,10 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { WebSiteManagementModels } from '@azure/arm-appservice';
import { StringDictionary } from '@azure/arm-appservice';
import { ParsedSite } from '@microsoft/vscode-azext-azureappservice';
import { IActionContext } from '@microsoft/vscode-azext-utils';
import * as vscode from 'vscode';
import { ParsedSite } from 'vscode-azureappservice';
import { IActionContext } from 'vscode-azureextensionui';
import { extensionVersionKey, ProjectLanguage, runFromPackageKey, workerRuntimeKey } from '../../constants';
import { ext } from '../../extensionVariables';
import { FuncVersion, tryParseFuncVersion } from '../../FuncVersion';
@ -21,7 +21,7 @@ type VerifyAppSettingBooleans = { doRemoteBuild: boolean | undefined; isConsumpt
export async function verifyAppSettings(context: IActionContext, node: SlotTreeItemBase, projectPath: string | undefined, version: FuncVersion, language: ProjectLanguage, bools: VerifyAppSettingBooleans): Promise<void> {
const client = await node.site.createClient(context);
const appSettings: WebSiteManagementModels.StringDictionary = await client.listApplicationSettings();
const appSettings: StringDictionary = await client.listApplicationSettings();
if (appSettings.properties) {
await verifyVersionAndLanguage(context, projectPath, node.site.fullName, version, language, appSettings.properties);

Некоторые файлы не были показаны из-за слишком большого количества измененных файлов Показать больше