import * as path from "path"; import * as vscode from "vscode"; export class ConfigStore { getProjectTaskPath(): string | undefined { const workspaceRoot = vscode.workspace.workspaceFolders?.[0]?.uri.fsPath; if (!workspaceRoot) return undefined; const config = vscode.workspace.getConfiguration("projectTasks"); const relativePath = config.get("projectPath") ?? ".vscode/tasks"; return path.join(workspaceRoot, relativePath); } getGlobalTaskPath(): string | undefined { const config = vscode.workspace.getConfiguration("projectTasks"); const globalPath = config.get("globalPath"); return globalPath || undefined; } getFileExtension(): string { const config = vscode.workspace.getConfiguration("projectTasks"); return config.get("fileExtension") ?? ".task.md"; } }