Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/fsharp/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Visual studio 2015 Visual Studio 2015挂起导入大型文件夹结构_Visual Studio 2015_Bower - Fatal编程技术网

Visual studio 2015 Visual Studio 2015挂起导入大型文件夹结构

Visual studio 2015 Visual Studio 2015挂起导入大型文件夹结构,visual-studio-2015,bower,Visual Studio 2015,Bower,我正在尝试将材质设计图标bower包加载到.net core web app中的wwwroot文件夹中。只需将material design图标文件夹复制到wwwroot的lib目录中,就会导致visual studio 2015挂起 visual studio使用此文件夹结构到底做了什么?它是否在某处缓存文件夹结构?我可以采取什么措施来加快visual studio使用此文件夹所做的任何事情吗?我尝试了一些方法来提高visual studio的性能,但最终不得不克服这些限制。尝试了一些与IO相

我正在尝试将材质设计图标bower包加载到.net core web app中的wwwroot文件夹中。只需将material design图标文件夹复制到wwwroot的lib目录中,就会导致visual studio 2015挂起


visual studio使用此文件夹结构到底做了什么?它是否在某处缓存文件夹结构?我可以采取什么措施来加快visual studio使用此文件夹所做的任何事情吗?

我尝试了一些方法来提高visual studio的性能,但最终不得不克服这些限制。尝试了一些与IO相关的项目,如禁用防病毒。我还尝试在VisualStudio中禁用源代码管理和各种隐藏文件夹解决方案。我最终选择从解决方案中完全删除material icons文件夹,并在发布过程中将其添加回去。我还必须做一些“摇树”,这样只有我实际使用的图标才会被发布。我通过扫描所有的cs和cshtml文件来查看图标的使用情况,然后只复制这些文件。以下是脚本,以防对其他人有所帮助:

function Publish-MaterialIcons{
[cmdletbinding()]
param(
    [Parameter(Position=0, Mandatory=$true)]
    [string]$path
)
process{
    $mdPath = "D:\media\material-design-icons"
    $publishPath = $(Join-Path $path "wwwroot\lib\material-design-icons")
    if (!(Test-Path $publishPath))
    {
        robocopy $mdPath $publishPath /e /xf *.* | Out-Null
    }

    "Adding $publishPath"
    $includeFonts = ls -Recurse -Include "*.cs", "*.cshtml" |% {cat $_} |? {$_ -match "([\w_]+)\</i\>"} |% {$matches[1]} | select -Unique |% {"*$_*.png","*$_*.svg"}
    $mdPathR = $mdPath -replace "\\", "\\" 
    $publishPathR = $publishPath -replace "\\", "\\"
    $(ls $mdPath -Recurse -include $includeFonts) + $(ls $mdPath -Recurse -Exclude "*.png", "*.svg")  |% {
        $newPath = join-path $($(Split-Path $_.FullName) -replace $mdPathR, $publishPathR) $_.Name
        cp $_.FullName  $newPath -Force
    }
}
}
函数发布{
[cmdletbinding()]
param(
[参数(位置=0,强制=true)]
[字符串]$path
)
过程{
$mdPath=“D:\media\material design icons”
$publishPath=$(连接路径$Path“wwwroot\lib\material design icons”)
如果(!(测试路径$publishPath))
{
机器人复制$mdPath$publishPath/e/xf**|输出空值
}
“正在添加$publishPath”
$includeFonts=ls-Recurse-Include“*.cs”、“*.cshtml”{cat$}}{124;?{$}-match“([\w\u]+)\”}}{$matches[1]}}选择-唯一的{cat$$$}png、“*$.*.svg”}
$mdPathR=$mdPath-替换“\\”、“\\”
$publishPathR=$publishPath-替换“\\”、“\\”
$(ls$mdPath-Recurse-include$includeFonts)+$(ls$mdPath-Recurse-Exclude“*.png”,“*.svg”)|%{
$newPath=join path$($(分割路径$\完整名称)-替换$mdPathR、$publishPathR)$\完整名称
cp$\全名$newPath-强制
}
}
}