Will the settings & extensions would be retained after switching to new Windows setup? - visual-studio-code

I did the update and got recommendation I now use new Windows Setup. I clicked learn more and went to site page that said I would be prompted to switch and all my settings & extensions would be retained, but there was no prompt to switch. The prompt was to download. I did, and when went to install, got message saying I should uninstall prior installation. It is not at all clear that my settings and extensions will in fact be kept. Does anyone know for sure. I don't want to uninstall, install new version, and then discover that all my settings and extensions have been wiped out. Please help?

Sorry, I should have followed up on this a long time ago. My question wasn't at all clear. It was about updating to a new version of Visual Studio Code. I had been instructed to uninstall the prior installation first. I feared that uninstalling would wipe out all my prior settings and configuration changes.
I later found from VSCode that uninstalling would not do so, but that they would be retained in the new installation. They were.

I am not sure if the settings and extension are preserved when you are making the switch.
But I can recommend few ways in which you can preserve your settings and extensions.
Sync settings
Create a symbolic link between both of your editors in which you can share the same setting and extension, without worrying about keeping the setting and extension in sync with both the editors.

Related

How to update VS Code on Windows?

I have VS Code version 1.37.1 and I want to update to the current available version 1.43. My OS is Windows 10.
How can I update the current version to the latest?. Like in Eclipse, check for updates is not updating the installation, rather it gives me a zip.
VS Code will automatically update itself on windows 10. If you'd like to force an update check there's an option available for that under 'Help > Check for Updates'.
If the update still doesn't complete, you can run the installer from here as described in the official Visual Studio Code Documentation under Docs » Supporting » Howtoupdate, found here.
If Update:Mode in VS Code's setting is on 'none' , 'Check for Updates ...' option will disappear from Help. Just be sure it's not on 'none' then you can check for updates.
2021-12-15, if you don't see Check for Updates... then Settings
Make sure it's not none
Then Help, Check for updates..., it won't auto-install. Once it downloads the update, either Help, Install update, or
Normally you don't need to do anything. The default configuration auto-updates and tells you it needs a restart.
If you experience different behaviour then either someone has interfered with settings in VS Code or the platform (Win/Lin/Osx) is misconfigured.
Type Ctrl+, or your platform equivalent and then filter for "update", then inspect your settings to see what may be mucked up. You can also force an update in the Help menu, and if this results in the download of a zip file it's not VS Code that's messed up, it's your platform.
Running this from the command prompt seemed to work for me:
winget upgrade --id Microsoft.VisualStudioCode
I think because I was running vscode as administrator I did not see the Help->Check for updates menu item.
My problem was that I had VS Code open as Administrator. After closing it and opening it normally I got the update to appear once again under the settings icon and in the Help menu.
If you cannot do that you can trigger the update with this command written in the terminal:
winget upgrade --id Microsoft.VisualStudioCode
My problem was with a later version, where update options did not appear under the Help menu. This may be because I ran a user install on a Win 2022 VM where I am Administrator user.
The above solutions did not work but I was able to resolve by running the latest user installer over the existing install (turns out the user install of VS Code does not appear in Control Panel, Uninstall program listing.) Currently this can be downloaded from https://code.visualstudio.com/.
If your update settings are OK, then there is one other possibility. Normally, you would have installed this huge piece of bloatware for your own user account only, using the "VSCodeUserSetup-.exe" installer.
But there is also a "system installer" which installs VSCode into "C:\Program Files" (configuration is still kept per-user). If you installed "VSCodeSetup-.exe" (note: no "User" in the installer file name), then you have an administrative install and will not get full auto-updates, AFAIK.

Latex file on vs code does not autocompile on save

I use the extension Latex Workshop, however my preview does not auto update on save. I have to run pdflatex each time.
I tried uninstalling and installing the extension, deleting the extensions file, and even reinstalled vs code. Yet, the same thing persists.
Is there a specific setting, etc that needs to be changed?
Strangely for me it only seems to work when configuring
latex-workshop.latex.autoBuild.run: "onSave"
As from here the setting for this is:
latex-workshop.latex.autoBuild.run
With value "onFileChange".
Note that this is the default value for this setting, so it should detect the changes automatically, but give it a try.
Local and ssh installation:
For me the problem was that I had Latex Workshop installed on SSH but not locally. After installing locally, the LaTEX icon showed up and also auto-compile on save worked right away.

VSCode system-wide installation warning

These days, anytime I start VSCode, I get this warning
You are running the system-wide installation of Code, while having the user-wide distribution installed as well. Make sure you're running the Code version you expect.
Please how do I fix that?
UPDATE (Recommended by #Fabio Turati)
Just uninstalling the older one without the (USER) extension, it seems working. If not, then uninstall the one left and reinstall vscode.
additional reading:
You installed the new one (with USER extension) before uninstalling the older one. So now you have both, and this is why you get that message. You need to uninstall them both, then reinstall vs code. Make sure you add a shortcut on desktop, it took me a few more minutes to find the .exe of vs code. No worries you don't lose anything by uninstalling...
cheers !
You probably have both versions installed (like I do).
To get rid of the warning, make sure you open the user-wide version. That means unpinning the one you used to have from everywhere.
Then use windows (10) search: visual studio code . Only the ' user-wide distribution' gets shown. If you open visual studio code that way, the warning is gone.
i had these installed:
uninstalled the first one and that error message is gone.
The new executable of the "user-wide distribution" is in this location by default:
C:\Users\<username>\AppData\Local\Programs\Microsoft VS Code\Code.exe
Replacing your shortcuts with this one should make sure you are using the new installation. (You can also uninstall the old one of course if you want to)
Run into this issue today but all I did was install the new one one (with user extension) and then after successful installation I uninstalled the the old one. Restart my computer and all seems to be ok.
I magically solved by (using windows 10):
Unpin from "taskbar" the vs code shortcut
Remove the shortcut from desktop also if you have it
Search on cortana "visual studio code", once the app appears right click and select "pin to taskbar"
Open tha vs code app from taskbar and the error should be gone.

VScode deleting itself

I have a problem where my VSCode keeps deleting itself after I do anything on it. e.g. when I code in Latex or just using it as a text editor, the entire code.exe itself keeps deleting itself. I have been downloading the latest version from the website itself but it still does the same thing with deleting itself.
PS. When I say deleting itself, I meant the entire VSCode uninstalls itself.
Thanks.
There are several steps to kinda fix this:
First run troubleshooter.
https://i.stack.imgur.com/jRdXI.png
If the problem continues, uninstall using unins000.exe in the folder where you installed vscode, and reinstall it.
If you use insiders build, kindle use the standard or non-insiders version.
If the problem still continues, check for updates in your pc and make sure you have updated your pc to the latest.
It should work after this, if not kindle contact the vscode support through get help app or your pc's manufacturer's support team.
Hope this helps in your wonderful coding journey!!

Receiving error message 'Extension host terminated unexpectedly.' in Visual Studio Code

I have been looking around and I haven't found any answers to my issue.
I keep getting this error "Extension host terminated unexpectedly." and I have tried removing all of my extensions, reinstalling the program, trying different versions of vscode including the insider versions.
The way I get this isssue isn't from trying to use the debugger or trying to use some sort of extension, as I said before I removed all of them and the error keeps on coming back, it's simply from opening the application. I'm not entirely sure how to continue? I have had to use another editor because the error just doesn't go away. I will just have to wait for another update of Visual Studio Code I assume? I've had the issue since tuesday this week, guessing since the latest update.
Above is the error message I get. It is closed by esc but reappears very shortly after, every time.
When I open developer tools, this is what I find in the console.
Running vscode from command prompt with Code.exe --disable-extensions doesn't help.
Visual Studio Code version: 1.16.1
I appreciate any help.
Linking my github issue on Microsoft/vscode as reference
I had the same error after updating vsc to v. 1.31.0.
Disabling Live Server Extension worked for me.
Here's the error i'm getting having the extension enabled.
I started getting this error when vscode automatically updated to March 2020 (version 1.44). I have tried various suggestions given in the forum and over the internet but none of them worked.
What worked for me: I downloaded January 2020 (version 1.42) build from https://code.visualstudio.com/updates/v1_42 and ran over the previous installation without uninstalling and surprisingly, the error disappeared and all extensions are loading and working properly.
I tried following things and non of them worked:
I disabled all the installed extension from GUI.
uninstalled all the extension and installed again.
removed the left-over extensions from Windows %USERPROFILE%.vscode\extensions.
tried launching from the command prompt with --disable-extensions option.
Linking my github issue on Microsoft/vscode as reference.
It ended up being one of the base extensions that runs on startup that was the root of the problem.
In my case the git in extensions folder was causing it.
"git.enabled": false was not doing the trick so I had to remove the git folder altogether for the error to disappear.
In my case, I used typescript-hero extension. Disabling this extension fixed my problem.
It's temporal fix but maybe will help somebody.
I disabled all the extensions with name Live for example Live Server, Live Share etc and restarted my vscode again and it worked for me.
For me this was happening due to HTML CSS Support extension. so i removed it and restarted vs code and voila! it worked!
I had to uninstall few extensions related to Java (debugger for java, Test runner for java, extension pack for java etc) to make the error go away.
Click on the developer tool option that popups and see if it has the extension which is causing this error.
I got same issue and it was because of Color Highlight Extension. I just uninstalled Color Highlight Extension and its working fine and NO ERROR.
Me too. My failure has no "Code":
Extension host terminated unexpectedly. Code: null Signal: SIGABRT
MessageService.ts
I recently ran into the same error message after accepting a permission to run a program on the extension livepreview. It corrupted all other extensions where it could not find the commands. I deleted all extension files and reinstalled the other extensions without a problem. I tried liveserver again but It never prompted me again for permissions and still, the error message keeps occurring. I'm assuming liveserver was trying to ask the computer permission to run a local server after which is still accepted but something else is interfering with the computer being able to translate from the program to actually building and accessing the local server.
In my case, the live server extension was causing this issue in 1.31.0v of VS Code. After uninstalling the extension it started working correctly.
In my case it was from the extension "Todo Tree". It was breaking on a particularly large file in my project (13.7mb), with the error saying the file was over the max-size for a node-buffer (used by the C regex matcher).
Resolved the issue by disabling the extension.
I also opened an issue for it here: https://github.com/Gruntfuggly/todo-tree/issues/135
I had same problem with following error in my VSCode console.
`1: node::DecodeWrite
2: node::InternalCallbackScope::Close
3: v8::internal::VirtualMemory::TakeControl
4: v8::internal::PerThreadAssertScope<4,1>::PerThreadAssertScope<4,1>
5: v8::internal::operator<<
6: v8::internal::operator<<
7: 00000073ECF04481`
I solved it by uninstalling Angular Console extension. Not sure if it was that particular extension or some other memory issue but problem went away as soon as I uninstalled that.
Remove all Extensions which are located in a per user extensions folder. Depending on your platform, the location is in the following folder:
Windows %USERPROFILE%\.vscode\extensions
macOS
~/.vscode/extensions
Linux ~/.vscode/extensions
Restart vscode and start installing extensions.
I am not sure why this caused , but the Antivirus was throwing popups that something like extensionprocess.js file was repaired.
Disabled the Antivirus and re-installed Vscode and it was back to normal.
Hope this helps.
Here is what helped me:
Ctrl+Shift+P --> type: "Disable"
and click Disable all installed extensions
(alternatively click Disable all installed extensions for this Workspace)
Then go to extensions panel on the left and re-enable slowly those that you really need.
See which extension (or their combination) triggers that error.
It will be highly appreciated which extenstion/combination you'll find guilty as there may be several of them, and different in time...
for me, it was code runner extension I just disabled it.