I saw when I tried to open an 80MB txt file that some features were disabled to prevent crashes or not. I accidentally clicked forcibly reenable extensions but now vscode is extremely laggy when I try to browse the file.
Does anyone know how to re-disable those extensions like tokenization when opening large files again?
Try disabling this setting:
Editor: Large File Optimizations
Special handling for large files to disable certain memory-intensive features.
Related
I recently moved to VSCode from Notepad++, and I just found an annoying difference.
When I had for example n files opened in Notepad++ and I closed it(also if restarting computer), when re-opening it I used to find those files again, also if they were deleted from folder or edited.
In VSCode, just some files are keeping opened(it depends if you have got them locally or download once and then delete or refresh them), and that's an annoying thing for me.
I guess this function is related to cache system, so I am wondering: Is there any method to make the VSCode cache work like Notepad++'s does in VSCode? Are there any extensions to do it?
I mean: to keep files always in cache, except when I close them.
Thank you in advance
I have been trying to figure this out, and cannot determine if it is possible or not.
Essentially, I commonly work with a VSCode window containing many files located on an external network drive (CIFS mount in Linux). When these files are changed "on-disk", they do not update in the editor until I switch focus to each file by changing the active editor tab. This means I have to switch tabs, wait for the update to process, and then repeat for all open tabs (could be 10 or 20 tabs).
Is there anyway to force all open editors to refresh or revert at once? That would ease my workflow a lot for examining differences between these open files on the fly. There's a command to "Revert File", but that only works on the open file, rather than all currently-opened ones. I've looked in the settings and browsed for an extension, but I can't find anything to accomplish this task.
Well, You can try to map the external network drive to local disk and give appropriate permission for read and write restriction.
If your computer has firewall or anti virus installed, then you must exclude vs access restriction from fw/av inspection.
Otherwise you can also improve your network adapter performance, associate to buffers, throughput, packet latency, etc.
Alternatively, you can use any source control, so your codes could be persist locally and could be synchronized from/to source control server.
Hope this could helps.
In my project, I've used some build/linting tools so they can automate force change my code based on some convention code styles but when I was running those scripts, vs code showed an error message:
Failed to save "<file-name>": The content on disk is newer. Please compare your version with the one on disk.and continue to open the "Resolve to save conflict" tab.
It seems to be annoying and not convenient for me.
So can you tell me how to disable this feature of VScode for a temporarily time?
v1.42 is modifying this functionality including adding a setting so that the dirty file/save conflict notification can be disabled. See https://github.com/microsoft/vscode-docs/blob/vnext/release-notes/v1_42.md#ignore-save-conflicts
Ignore save conflicts
VS Code has a built-in mechanism to show an error when you try to save
a dirty file that has been changed outside of VS Code or by another
program (for example Git):
The motivation is to inform you that saving will overwrite the
contents on disk even though the file was changed after the file
became dirty. Clicking the Compare button lets you review your change
along with the version on disk and either overwrite or revert the
file.
In cases where you know that the changes on disk can be overwritten,
there is now an Overwrite button directly on the notification. You can
also configure files.saveConflictResolution globally or per workspace or
file type to disable the notification altogether. The options are askUser (default) or overwriteFileOnDisk.
I am currently using VS Code on a folder mounted through an SSHFS. The folder has subfolders with many jpg and other image files.
Logging all the files VS Code tries to open reveals it recursively touches all the files (doesn't read the content, just STATs them). This takes very, very long over an SSHfs mount and I can not cancel it without killing the editor (it won't even respond to regular closing).
During this, no files or directories can be opened (inside VSCode) and will show a loading spinner until VS Code has finally had it's way and checked all the files.
This behaviour only recently emerged, I can't pinpoint if any version beyond the current stable version has this behaviour.
I am thinking it might be the new searching engine, but I can't find out which part of the editor is doing it.
It looks like they just posted a fix for your situation:
Slow startup opening a large workspace over the network
you will need vscode v1.32.3
VSCode slow to open and highlight large log files
I use VSCode to open large log files with the log highlighter syntax. These log files are very large, often a couple hundred megabytes. I switched from Notepad++ to VSCode for all the features. Notepad++ usually opened the files okay but lacked the highlighting benefits.
The new VSCode updates asked me to increase memory size which I quadrupled.
However some logs either take a while to highlight or never do at all.
Is there anyway to either speed this up or get this to work a bit better? Should I open a github issue?
I would really like to use VSCode for these logs but it is annoying...
Resources on PC are not an issue.