From 35c20b80df8afcdb46059b58e6c38302da060873 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kevin=20Iv=C3=A1n=20Dom=C3=ADnguez=20Jim=C3=A9nez?= Date: Tue, 23 Sep 2025 08:42:32 -0600 Subject: [PATCH] before release 3 --- package.json | 5 ++++- src/extension.ts | 8 +++++--- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index af15c3a..3d20d9f 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,10 @@ "name": "format-4690", "displayName": "format-4690", "description": "Formatter for 4690 BASIC", - "version": "0.0.1", + "version": "0.0.2", + "repository": { + "url": "https://git.kidj.dev/IvanovichRU/4690-BASIC-Language-Support.git" + }, "engines": { "vscode": "^1.101.0" }, diff --git a/src/extension.ts b/src/extension.ts index 962ff4c..45361f9 100644 --- a/src/extension.ts +++ b/src/extension.ts @@ -1,5 +1,6 @@ import * as vscode from 'vscode'; import { FunctionDefinition, parseFunctionDefinitions } from './functions'; +import path from 'path'; // Global symbol index - maps lowercase function names to their definitions const symbolIndex = new Map(); @@ -67,9 +68,6 @@ export async function activate(context: vscode.ExtensionContext) { } }); - - - // Existing formatter provider (unchanged) const formatterProvider: vscode.DocumentFormattingEditProvider = { provideDocumentFormattingEdits(document: vscode.TextDocument): vscode.TextEdit[] { @@ -267,6 +265,8 @@ export async function activate(context: vscode.ExtensionContext) { console.log('Building symbol index...'); const workspaceFiles = await vscode.workspace.findFiles('**/*.{bas,BAS,j86,J86}'); + await updateIndexForFile(vscode.Uri.file(path.join(vscode.extensions.getExtension('undefined_publisher.format-4690')!.extensionPath, 'static', '4690functions.BAS'))); + for (const fileUri of workspaceFiles) { try { await updateIndexForFile(fileUri); @@ -608,6 +608,8 @@ export async function activate(context: vscode.ExtensionContext) { // Prefer definition from current document, otherwise use first one const definition = definitions.find(def => def.location.uri.toString() === document.uri.toString()) || definitions[0]; + + const content = new vscode.MarkdownString(); // Build function signature with parameters