-
Notifications
You must be signed in to change notification settings - Fork 30.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
findFiles ignores 'base' part of exclude glob #52651
Comments
@roblourens that looks like a bug to me, I would also expect to find any *.ts file from the first workspace folder. |
On the same idea, I'm trying to give users the possibility to include folders in a file search, in a multi or single root workspace. let globPatternSource = `**/*.yml`;
if (sourceFolders !== undefined && sourceFolders.length > 0) {
globPatternSource = `{${sourceFolders.join(",")}}/**/*.yml`;
}
vscode.workspace.findFiles(globPatternSource); On a single root workspace it works fine, but with multi-root they can't just include "rootA", they would have to include all of rootA subfolders because the roots are already included in the search path. Is that the same issue or is that intentional? |
Sorry I don't understand what you're trying to do. You want to search a root, but not search its subfolders? |
Sorry I wasn't clear. RootA:
RootB:
I'd like To me, the root folders shouldn't be included in the query. Was I clearer? |
I see - this is what |
@roblourens do you know if this is still an issue? |
|
This issue has been closed automatically because it needs more information and has not had recent activity. See also our issue reporting guidelines. Happy Coding! |
This searches for *.ts files and excludes .ts files in the second workspace folder.
When I run this, I get 0 results, when it should return results from the first workspace folder.
Seems like it's always been that way. Is that intentional @bpasero? If not I can fix it. We can pass absolute exclude globs to search.
https://github.com/Microsoft/vscode/blob/b7e6e04666ca8dde560b69081c43365dce77d12a/src/vs/workbench/api/node/extHostWorkspace.ts#L357
The text was updated successfully, but these errors were encountered: