提交 52d0befd 编写于 作者: R Rob Lourens

Fix #38165 - fix search includes/excludes in UNC paths

上级 8426b611
......@@ -375,8 +375,13 @@ function globExprsToRgGlobs(patterns: glob.IExpression, folder?: string, exclude
const value = patterns[key];
key = trimTrailingSlash(folder ? getAbsoluteGlob(folder, key) : key);
// glob.ts requires forward slashes
key = key.replace(/\\/g, '/');
// glob.ts requires forward slashes, but a UNC path still must start with \\
// #38165 and #38151
if (strings.startsWith(key, '\\\\')) {
key = '\\\\' + key.substr(2).replace(/\\/g, '/');
} else {
key = key.replace(/\\/g, '/');
}
if (typeof value === 'boolean' && value) {
globArgs.push(fixDriveC(key));
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册