feat(vscode) Agent Manager (#87)
* Add Agent Manager * Basic Mock UP * Fix Comand naming Ctrl+P Uses Category to group * Move the UI in views * Agent Manager Landing Page * Fix attachment buig * Change Session Name for multi run to incoporate groupSlug * First running UI * Fix Max Model Multi Run * Rework Agent Group detection * ignore false positives with ' ' in it * Simplify Logic * remove unused dropdowns * Clean up * Update Changelog
This commit is contained in:
@@ -1,8 +1,10 @@
|
||||
import * as vscode from 'vscode';
|
||||
import { ChatViewProvider } from './ChatViewProvider';
|
||||
import { AgentManagerPanelProvider } from './AgentManagerPanelProvider';
|
||||
import { createOpenCodeManager, type OpenCodeManager } from './opencode';
|
||||
|
||||
let chatViewProvider: ChatViewProvider | undefined;
|
||||
let agentManagerProvider: AgentManagerPanelProvider | undefined;
|
||||
let openCodeManager: OpenCodeManager | undefined;
|
||||
let outputChannel: vscode.OutputChannel | undefined;
|
||||
|
||||
@@ -144,6 +146,15 @@ export async function activate(context: vscode.ExtensionContext) {
|
||||
|
||||
void maybeMoveChatToRightSidebarOnStartup();
|
||||
|
||||
// Create Agent Manager panel provider
|
||||
agentManagerProvider = new AgentManagerPanelProvider(context, context.extensionUri, openCodeManager);
|
||||
|
||||
context.subscriptions.push(
|
||||
vscode.commands.registerCommand('openchamber.openAgentManager', () => {
|
||||
agentManagerProvider?.createOrShow();
|
||||
})
|
||||
);
|
||||
|
||||
context.subscriptions.push(
|
||||
vscode.commands.registerCommand('openchamber.restartApi', async () => {
|
||||
try {
|
||||
@@ -415,6 +426,7 @@ export async function activate(context: vscode.ExtensionContext) {
|
||||
context.subscriptions.push(
|
||||
vscode.window.onDidChangeActiveColorTheme((theme) => {
|
||||
chatViewProvider?.updateTheme(theme.kind);
|
||||
agentManagerProvider?.updateTheme(theme.kind);
|
||||
})
|
||||
);
|
||||
|
||||
@@ -429,6 +441,7 @@ export async function activate(context: vscode.ExtensionContext) {
|
||||
event.affectsConfiguration('workbench.preferredDarkColorTheme')
|
||||
) {
|
||||
chatViewProvider?.updateTheme(vscode.window.activeColorTheme.kind);
|
||||
agentManagerProvider?.updateTheme(vscode.window.activeColorTheme.kind);
|
||||
}
|
||||
})
|
||||
);
|
||||
@@ -437,6 +450,7 @@ export async function activate(context: vscode.ExtensionContext) {
|
||||
context.subscriptions.push(
|
||||
openCodeManager.onStatusChange((status, error) => {
|
||||
chatViewProvider?.updateConnectionStatus(status, error);
|
||||
agentManagerProvider?.updateConnectionStatus(status, error);
|
||||
})
|
||||
);
|
||||
|
||||
@@ -449,6 +463,7 @@ export async function deactivate() {
|
||||
await openCodeManager?.stop();
|
||||
openCodeManager = undefined;
|
||||
chatViewProvider = undefined;
|
||||
agentManagerProvider = undefined;
|
||||
outputChannel?.dispose();
|
||||
outputChannel = undefined;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user