Skip to content

Commit

Permalink
Allow root meson.build files to be symlinks
Browse files Browse the repository at this point in the history
  • Loading branch information
tristan957 committed Nov 29, 2023
1 parent 4517d74 commit 9e6632a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

## next

- Also check for root `meson.build` files which are symlinks

## 1.19.1

- Fix extension not calling Meson correctly in some circumstances like Cygwin
Expand Down
2 changes: 1 addition & 1 deletion src/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ export async function mesonRootDirs(): Promise<string[]> {
let hasMesonFile: boolean = false;
let subdirs: vscode.Uri[] = [];
for (const [name, type] of await vscode.workspace.fs.readDirectory(d)) {
if (type === vscode.FileType.File && name == "meson.build") {
if ((type === vscode.FileType.File || type === vscode.FileType.SymbolicLink) && name == "meson.build") {
rootDirs.push(d.fsPath);
hasMesonFile = true;
break;
Expand Down

0 comments on commit 9e6632a

Please sign in to comment.