重命名文件时,Visual Studio 速度非常慢 [英] Visual Studio incredibly slow when renaming files

查看:58
本文介绍了重命名文件时,Visual Studio 速度非常慢的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个中等规模的解决方案,其中包含 99 个最近开始出现异常行为的项目:

I have a medium-sized solution with 99 projects that has recently started behaving weirdly:

1) 如果我尝试通过解决方案资源管理器重命名文件,VS 似乎会挂起,但经过很长时间(10 分钟以上)后,它会完成重命名操作.

1) If I try to rename a file through the solution explorer, VS will seemingly hang, but after a long time (10+ minutes) it will complete the rename operation.

2) 我今天还注意到,在调试和发布模式之间切换似乎也会冻结 VS.到目前为止,我还没有让它运行足够长的时间来查看它是否真的完成.

2) I also noticed today that switching to between Debug and Release mode seems to freeze VS as well. So far I haven't let it run long enough to see if that actually completes.

我已经尝试了 Visual Studio 2012 和 2013,并且都出现了相同的问题,所以这似乎表明问题可能不在 Visual Studio 中.我试图检查事件日志中是否有任何内容,但没有任何内容出现在我身上.我也重新启动并运行 checkdisk,但没有发现任何问题.

I've tried both Visual Studio 2012 and 2013, and both exhibit the same problem, so that seems to indicate the problem might not be with Visual Studio. I've tried to check in the event log if there's anything there, but nothing jumped out on me. I've also rebooted and run checkdisk, but it didn't find anything wrong.

在配备 8GB RAM 和新 SSD 的相当高规格的笔记本电脑上运行 Windows 7 Professional

Running Windows 7 Professional on a fairly high-specced laptop with 8GB RAM and a new SSD

更新:显然,如果我重命名了一个文件,我可以立即继续重命名它(以及解决方案中的其他文件).当我重新启动 VS 时,它又变慢了.

Update: apparently if I have renamed a file once, I can keep renaming it (and other files in the solution) immediately. When I restart VS, it's slow again.

更新 2:我让计算机运行了一夜,试图从调试切换到发布,它在我下班和回到这里之间的 14 小时内成功做到了.

Update2: I left the computer running overnight to try to switch from Debug to Release, and it managed to do so in the 14ish hours between me leaving work and getting back here.

推荐答案

在测试时,我尝试将其中一个项目设置为在不同的服务器上构建,包括调试和发布模式.虽然我已经清理了两者,但显然我只在 Debug 配置下这样做.

When testing I'd made an attempt at setting up one of the projects to build on a different server, both in Debug and Release mode. I though I'd cleaned up both, but apparently I'd only done so under the Debug configuration.

显然,同时那个服务器已经决定它讨厌我的机器,这使得我的机器在等待它时冻结.

Apparently meanwhile that server has decided it hates my machine, which makes my machine freeze while waiting for it.

关闭 Visual Studio 并手动编辑 .csproj 文件解决了问题.

Closing Visual Studio and manually editing the .csproj file solved the problem.

这篇关于重命名文件时,Visual Studio 速度非常慢的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆