Skip to content

Commit

Permalink
Do not run meson setup if meson.build selection was cancelled.
Browse files Browse the repository at this point in the history
  • Loading branch information
wolfpld authored and tristan957 committed Nov 14, 2023
1 parent 38d78c1 commit 51e7d5f
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/extension.ts
Original file line number Diff line number Diff line change
Expand Up @@ -235,6 +235,7 @@ export async function activate(ctx: vscode.ExtensionContext) {
}

if (configureOnOpen) {
let cancel = false;
if (!configurationChosen && mesonFiles.length > 1) {
const items = mesonFiles.map((file, index) => ({ index: index, label: relative(root, file.fsPath) }));
items.sort((a, b) => a.label.localeCompare(b.label));
Expand All @@ -248,8 +249,11 @@ export async function activate(ctx: vscode.ExtensionContext) {
await workspaceState.update("mesonbuild.configurationChosen", true);
vscode.commands.executeCommand("workbench.action.reloadWindow");
}
cancel = selection === undefined;
}
if (!cancel) {
runFirstTask("reconfigure");
}
runFirstTask("reconfigure");
}
} else {
await rebuildTests(controller);
Expand Down

0 comments on commit 51e7d5f

Please sign in to comment.