Fix list_files fast-glob implementation; update system prompt to prefer analyze_project over list_files; lock editor tab when opened for better UX

This commit is contained in:
Saoud Rizwan
2024-07-27 14:11:56 -04:00
parent 9fa611cb3d
commit 4facaede80
3 changed files with 31 additions and 29 deletions

View File

@@ -47,7 +47,7 @@ export function activate(context: vscode.ExtensionContext) {
})
)
const openClaudeDevInNewTab = async () => {
const openClaudeDevInNewTab = () => {
// (this example uses webviewProvider activation event which is necessary to deserialize cached webview, but since we use retainContextWhenHidden, we don't need to use that event)
// https://github.com/microsoft/vscode-extension-samples/blob/main/webview-sample/src/extension.ts
const tabProvider = new ClaudeDevProvider(context)
@@ -62,6 +62,11 @@ export function activate(context: vscode.ExtensionContext) {
// TODO: use better svg icon with light and dark variants (see https://stackoverflow.com/questions/58365687/vscode-extension-iconpath)
panel.iconPath = vscode.Uri.joinPath(context.extensionUri, "icon.png")
tabProvider.resolveWebviewView(panel)
// Lock the editor group so clicking on files doesn't open them over the panel
new Promise((resolve) => setTimeout(resolve, 100)).then(() => {
vscode.commands.executeCommand("workbench.action.lockEditorGroup")
})
}
context.subscriptions.push(vscode.commands.registerCommand("claude-dev.popoutButtonTapped", openClaudeDevInNewTab))