Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
microsoft
GitHub Repository: microsoft/vscode
Path: blob/main/test/mcp/src/automationTools/activityBar.ts
3520 views
1
/*---------------------------------------------------------------------------------------------
2
* Copyright (c) Microsoft Corporation. All rights reserved.
3
* Licensed under the MIT License. See License.txt in the project root for license information.
4
*--------------------------------------------------------------------------------------------*/
5
6
import { McpServer, RegisteredTool } from '@modelcontextprotocol/sdk/server/mcp.js';
7
import { ApplicationService } from '../application';
8
9
/**
10
* Activity Bar Tools
11
*/
12
export function applyActivityBarTools(server: McpServer, appService: ApplicationService): RegisteredTool[] {
13
const tools: RegisteredTool[] = [];
14
15
// Doesn't seem particularly useful
16
// server.tool(
17
// 'vscode_automation_activitybar_wait_for_position',
18
// 'Wait for the activity bar to appear at a specific position',
19
// {
20
// position: z.enum(['LEFT', 'RIGHT']).describe('Position of the activity bar (LEFT or RIGHT)')
21
// },
22
// async (args) => {
23
// const { position } = args;
24
// const activityBarPosition = position === 'LEFT' ? 0 : 1; // ActivityBarPosition.LEFT = 0, RIGHT = 1
25
// await app.workbench.activitybar.waitForActivityBar(activityBarPosition);
26
// return {
27
// content: [{
28
// type: 'text' as const,
29
// text: `Activity bar found at position: ${position}`
30
// }]
31
// };
32
// }
33
// );
34
35
return tools;
36
}
37
38