How do I turn off "Contains emphasized items" in Visual Studio code? - visual-studio-code

I need to figure out how to turn off emphasized items in Visual Studio Code
This might sound like a strange requirement, but in my workflow vscode functions as less an IDE than a cross-platform ViM-esque frontend with lots of remote development tools built-in.
Due to this use case, I don't need or want the linting features to show up in the file browser. How might I accomplish this?
Attempts to solve the problem
I've run out of search terms here and cannot find an answer.
Searches including terms in this question's title yielded little
SO-specific search queries also yielded little
This seems to be somewhat related, at least as a representation of the "feature" I'm referencing: VS code containes emphasized items but no error
VSCode "preferences" do not appear to show what I'm looking for, likely an issue with me not searching for the right variable name.
In my experience with VSCode it has been wonderfully customize-able, so I'm guessing there's a setting somewhere ready to be modified to accomplish this. Any help much appreciated, thanks!

My use case was a bit different: after viewing some files in a git submodule those files became linted, and errors and warnings cluttered up my VS Code Explorer file browser window on files I had no intention of ever handling. I basically wanted a way to clear out those lint warnings, and found it here. The solution is to reload the window:
CtrlShiftP on Windows/Linux, ⌘ShiftP on Mac -- then select "Developer: Reload Window"
One by-product of reloading the window is that it clears out those unwanted warnings (at least until the next time I visit the file). It also has the effect of clearing out warnings on files that I would normally want to see, of course, but chances are I'll be visiting those files again soon, so it's fine. Not a perfect solution, but it works for me and my use-case; hopefully it can help others.

I don't know how to turn it off, but I had this on multiple folders and I fixed it by renaming the folder to a random name, then naming it back to the name it was before and the error would go away.

If you have this issuse then uninstall extention then CtrlShiftP on Windows/Linux, ⌘ShiftP on Mac -- then select "Developer: Reload Window" then type developer: relode page this issuse automatically resovle
i have this issuse then i uninstall extension then this issuse resolve.

I was able to permanently prevent this by adding the files to the .gitignore file. It seems that this happens in a cloned repository when you add new files.

Related

Prevent VS Code from overwriting my clipboard when clicking a link in the terminal

VS Code has a neat feature where if you search for something in the terminal grep/ack or similar tools, the resultant file links are clickable (with ctrl+click). I love that feature! Recently however I reinstalled VS Code with fresh settings, and a strange new default behavior has started that was definitely not present in my old install. Whenever I click links like that, in addition to opening the link, the name of the file is also copied into my clipboard, overwriting what I searched for.
My old work flow was copy search term, go to console, grep <paste>, click link, ctrl+f, . That doesn't work anymore, and I would prefer to restore the old mechanism, but due to the somewhat peculiar circumstances I'm not sure what I would search for to configure this behavior.
Any ideas ?

How to expand VScode directories

I know this has been answered somewhere before, but for the life of me I cannot figure out how to properly Google this query. I got a new computer and I've mostly setup my Visual Studio Code environment, but I have never liked the shorthand directory structure if defaults to. I want to change my directories to be full dropdowns and not a one-line somedirectory/subdirectory/subdirectory/something.js
Apparently there is some fancy word for it but I have no idea what that word is and it's making my searching surprisingly difficult.
So, what setting do I need to change in VScode to make all of my directories follow the format that Collection has in the example below and not like lessons/flashcards?
Thanks!
TLDR; I want every directory to be a full dropdown. None of this lessons/flashcards nonsense.
To Achieve this go to your vs code settings and search Compact Folders. It will be checked by default. Uncheck that and it will work.

VS Code: when I close a sub-folder and return to the file, the sub-folder reopens

I've always developed with Sublime Text, but I feel that VS Code is much better, so I want to get started.
I have a problem please (with Sidebar of VS Code):
When I open a sub-folder in my project, and I open a file that is inside, I like to manually close this sub-folder (because I like to see the architecture of the project, etc.) and to continue working on its files which are already open in my editor.
For example (I work with Laravel): if I open a "User.php" file which is in the "App/Modals" folder, then I manually close the "App/Modals" folder, then I will work in another file, then I come back to work in "User.php", the "App/Modals" folder reopens by itself ...
I do not have this behavior with Sublime Text, nor with PHP Storm.
SVP: Is there a regulation to prevent this behavior?
Thank you.
There's an option to make this feature (it's not something that's just happening to you, it's a feature of VSCode) go away. Go to settings (ctrl + , or cmd + , on mac) and search for "explorer.autoReveal". Make sure it's unchecked, or set it to false in your setting's json.
Just by the way, I don't know if you did, or you didn't know what to search, but you should try to solve this kind of problems by googling for an answer. For instance, I didn't know the answer, but a simple 'disable auto opening folder vs code' in google brought me several results. Just a recommendation, so that you can learn how to solve your own problems and be more efficient.

Visual Studio Code search across files (find in files) is not working

I am using Visual Studio Code 1.31.1 in MacOS 10.13.6. I open VSCode, I open a folder of text files, and I press command-option-F, or use Edit -> Find in Files. I search for a string that I know for sure exists in multiple text files in the open folder, and it says it can't find it.
Searching across files works if I have the folder open and have each and every single file open as a tab, which is rather pointless. Is there a way to search across files without actually having them all open as tabs?
I think it was because I opened a folder on Google Drive File Stream. It works fine on local files.
In my case, this was caused by me accidentally toggling the "Search only in Open Editors" option.
Had this same issue, the search functionality was only working for files that were open in the editor. My issue was that VS Code had an update downloaded and ready to update, so I just restarted VS Code, let the update finish and the issue was gone.
It could be that the search is looking into all folders (including node_modules ones), so as it is too big, the search never ends
To fix that, you can list all folders that you want to exclude of the search, to do that, open your vscode settings (ctrl + ,) type "Search: Exclude" in the search box and add your folders. (Btw some are already added by default)
Besides, remember to enable that filter in your search, this is simple, just toggle on the gear button in your search section
If you are still not sure about what to do, take a look in this briefly gif
Had the same issue on Mac, seems like it was related to Google Drive. once I moved the files on my local drive the search worked fine.
Check out your vs code settings. It excludes some folders by default e.g. node modules.
Go to settings, search "Search" , there will be list to exclude folders.
Remove item which might be accidentally got included, which might causing search item in all directory is not working.
I had this problem today. Turns out I had a deprecated setting for advanced RegEx searches "search.usePCRE2": true, Once removed, search started working as expected.
I just had this problem on VS Code 1.58.2 / Mac OS 10.15.7
None of the above solutions worked for me, it still keeps saying 'No results found in open editors' no matter what I do.
But I did get it working by changing the 'Search: Mode' in the settings (for the workspace, or any other scope if needed) from 'view' to 'reuseEditor'.
Yes, this doesn't fix it if you really want the results in the Explorer tab rather than a completely new editor window, but it works.
I had the same issue, i fixed mine by removing files in .gitignore
I had an issue with searching in a project with git submodules and found that the gitlens add-on defaults to ignore searching any submodules:
Setting this to 2 or more may address your problem.
In my case, I had somehow gotten my Explorer set on a subfolder of my project. Closing VS Code and reopening the workspace reset everything and search worked again.
In my case, it was files with no extensions I was not able to find. Once I added those files an extension, I was able to find them via the search feature.
I initially wrote this answer describing a confusing "inverted" behavior of the Search only in Open Editors option/button.
However, after playing around it turns out that what the GUI was showing was not "in sync" with what the search results were returning. Toggling the options a few times appears to have fixed things.
So if your search doesn't appear to be returning any results, I would suggest toggling the Search only in Open Editors and Use Exclude Settings and Ignored Files options.
Otherwise, for information, here is my previous answer:
VS Code has an extremely confusing "inverted" interface when it comes to the option Search only in Open Editors.
There is also another option which affects how search works in a confusing way: Use Exclude Settings and Ignored Files.
The below screenshot shows both:
Note that:
Search only in Open Editors is OFF
Use Exclude Settings and Ignored Files is ON
With these options I get search results back, with them set the other way around - confusingly - I get nothing.
Important to note:
If you turn Use Exclude Settings and Ignored Files OFF, then VS Code seems to stop searching any files, EXCEPT for those which are currently open in tabs. This is very confusing and not the behavior one would expect. The expected behavior would probably be to search the whole opened Folder/Workspace by default.
If you turn Search only in Open Editors OFF, then only open editors will be searched. This is the "inverted" behavior. My current build of VS Code has the indicator "inverted" for this GUI element. When it looks like it is in the "ON" state, it is actually "OFF". When it looks like it is in the "OFF" state, it is actually "ON'.
These two things interact in unexpected ways: (This is the behaviour I observed after toggling both buttons a few times. It is different to what I was seeing a few minutes ago.)
Open Editors (looks like) it is OFF, Use Exclude Settings (looks like) it is ON, search appears to search whole workspace.
Open Editors (looks like) it is OFF, Use Exclude Settings (looks like) it is OFF, search appears to search open tabs only.
Open Editors (looks like) it is ON, Use Exclude Settings (looks like) it is OFF, search appears to search whole workspace.
Open Editors (looks like) it is ON, Use Exclude Settings (looks like) it is ON, search appears to search whole workspace.
I suspect that when typing / editing the search terms, replace option, and files to include/exclude options, VS Code does not check the state of the option buttons before performing the search. This is likely the source of the bug I was seeing earlier.

How to avoid Eclipse blocking keyboard shortcuts

I installed a plugin that allowed me to create UML diagram from my code. Everything was working fine until I found that now all keyboard shortcuts (like CTRL-X, CTRL-Z, CTRL-SPACE, CTRL-SHIFT-F,..) except for CTRL-C and CTRL-V now require a click on a small square that appear on the bottom right corner. And this is required every single time.
This are few examples of the square that appears:
If I click on the message or press Enter I can access the functionality. Does anyone know how to get rid of this annoying thing or at least reset Eclipse related configurations?
Thanks in advance
EDIT:
I obviously tried uninstalling the plugin but nothing changed.
Try Window / Reset Perspective as the duplicate shortcuts may be still in the perspective.
Also try restart specifying -clean option to rebuild the workspace metadata.
The pop-ups you are seeing are the "keybinding conflict" popups. These are common when you have two different plugins defining the same keybinding and looks like these. Still in your case there's only one option to choose from and it definitely looks like a bug.
In the Eclipse bugtracker database there are two issues that are looking like the one you have: #377048 and #374942.
These issues are marked as fixed in 4.2-I20120410-0633. So if you are having Eclipse 4.2 without any service releases installed, you would probably have this. The solution is - to use a newer Eclipse version. Eclipse 4.3.1 is available to download since today, and it should contain a lot of other fixes since 4.2. So I encourage you to install it.
The other solution could be to try playing with keybinding dialog (Window->Preferences->General->Keys) and trying to unbind and re-bind the commands that you are having issues with.