mirror of
https://github.com/QwenLM/qwen-code.git
synced 2025-12-20 08:47:44 +00:00
Add drawer for active files in IDE mode (#4682)
Co-authored-by: Shreya <shreyakeshive@google.com>
This commit is contained in:
@@ -252,8 +252,11 @@ const createMcpServer = () => {
|
||||
inputSchema: {},
|
||||
},
|
||||
async () => {
|
||||
const activeEditor = vscode.window.activeTextEditor;
|
||||
const filePath = activeEditor ? activeEditor.document.uri.fsPath : '';
|
||||
const editor = vscode.window.activeTextEditor;
|
||||
const filePath =
|
||||
editor && editor.document.uri.scheme === 'file'
|
||||
? editor.document.uri.fsPath
|
||||
: '';
|
||||
if (filePath) {
|
||||
return {
|
||||
content: [{ type: 'text', text: `Active file: ${filePath}` }],
|
||||
|
||||
Reference in New Issue
Block a user