Merge remote-tracking branch 'origin/switch_gpt_model' into 93-plugin-support-for-easy-switching-between-gpt35-and-gpt4
This commit is contained in:
commit
ec5912cb45
@ -16,6 +16,7 @@ import { listAllMessages } from './listMessages';
|
||||
import { regActionList } from './regActionList';
|
||||
import { applyAction } from './applyAction';
|
||||
import { doCommand } from './doCommand';
|
||||
import { updateSetting } from './updateConfig';
|
||||
|
||||
|
||||
// According to the context menu selected by the user, add the corresponding context file
|
||||
@ -82,3 +83,5 @@ messageHandler.registerHandler('askCode', askCode);
|
||||
// Execute vscode command
|
||||
// Response: none
|
||||
messageHandler.registerHandler('doCommand', doCommand);
|
||||
|
||||
messageHandler.registerHandler('updateSetting', updateSetting);
|
13
src/handler/updateConfig.ts
Normal file
13
src/handler/updateConfig.ts
Normal file
@ -0,0 +1,13 @@
|
||||
/*
|
||||
Update config
|
||||
*/
|
||||
|
||||
import * as vscode from 'vscode';
|
||||
import { regInMessage, regOutMessage } from '../util/reg_messages';
|
||||
import { logger } from '../util/logger';
|
||||
import { UiUtilWrapper } from '../util/uiUtil';
|
||||
|
||||
regInMessage({command: 'updateSetting', key1: "DevChat", key2: "OpenAI", value:"xxxx"});
|
||||
export async function updateSetting(message: any, panel: vscode.WebviewPanel|vscode.WebviewView): Promise<void> {
|
||||
UiUtilWrapper.updateConfiguration(message.key1, message.key2, message.value);
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user