最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

ide - How to stop Visual Studio (not Code) from pointing me to certain directories? - Stack Overflow

programmeradmin0浏览0评论

I have a big-ish legacy project and every so often when I use Ctl-Shift-T to got to a file by name (because it's convenient), I end up at some copied version (be it in .vshistory or source server, usually the latter).

At first I don't notice it because everything looks exactly as it should. Only when my changes aren't applied or all breakpoints refuse to work (even with the "require exact location match" off) I eventually realize it happened again.

So how to block (or at least deprioritize) Visual Studio code search from pointing me towards these files? (or make a popup or any notification that it happened again so I realize it before getting annoyed and confused why nothing works for 5 minutes before realizing)

Any and all answers I find are regarding VSCode (thanks Microsoft's naming schemes), which has a great solution for this issue that sadly doesn't apply to Visual Studio.

All I could find was a similarily unanswered Reddit post.

I have a big-ish legacy project and every so often when I use Ctl-Shift-T to got to a file by name (because it's convenient), I end up at some copied version (be it in .vshistory or source server, usually the latter).

At first I don't notice it because everything looks exactly as it should. Only when my changes aren't applied or all breakpoints refuse to work (even with the "require exact location match" off) I eventually realize it happened again.

So how to block (or at least deprioritize) Visual Studio code search from pointing me towards these files? (or make a popup or any notification that it happened again so I realize it before getting annoyed and confused why nothing works for 5 minutes before realizing)

Any and all answers I find are regarding VSCode (thanks Microsoft's naming schemes), which has a great solution for this issue that sadly doesn't apply to Visual Studio.

All I could find was a similarily unanswered Reddit post.

Share Improve this question asked Feb 6 at 12:19 HobbamokHobbamok 8502 gold badges12 silver badges23 bronze badges 1
  • You can also raise a feature request at Visual Studio Developer Community. – Dou Xu-MSFT Commented yesterday
Add a comment  | 

1 Answer 1

Reset to default 1

How to exclude specific folders when using code search in visual studio?

After searching MS documents, i am afraid that there is no some setting.json files like VSCode to configure excluded items.

However i have noticed a similar ticket reported earlier at here. It provides a solution to exclude folders but i found it does not work for VS2022 based on my test or maybe i miss something.

Create the “VSWorkspaceSesttings.json” file in your opened folder or its direct “.vs” subfolder with content like so:

{
  "ExcludedItems" : [
    "your excluded folder name/",
   ]
}

I would suggest you raise a feature request at Developer Community That will allow you to directly interact with the appropriate product group, and make it more convenient for the product group to collect and categorize your suggestions.

发布评论

评论列表(0)

  1. 暂无评论