Set Default settings for all users in VSCode - visual-studio-code

i haven't found a way to set the default settings for all our users on install for VSCode.
All i really need set automatically is the ' "http.proxyStrictSSL": false,' setting.
These are students i cant ask them to do it. Is it even possible?

As of VS Code 1.14, we do not support this scenario but we are tracking the features request here: https://github.com/Microsoft/vscode/issues/27972
As a workaround, you can try using an extension such as Fetch User Environment

Related

The meaning of profile contents checkboxes

The new version of VSCode 1.75 contains the new function Profiles, which I was waiting for.
It looks like you can install, activate or deactivate extensions in each profile, without affecting the other profiles.
So far I only managed to install, activate or deactivate extensions via the extension manager, or via the view page of the respective extension.
There is this new view that can be displayed via [Settings-Wheel]-[profiles]-[show contents]
There you can find a checkbox for each extension.
Intuitively, one would assume that the extensions for a profile can be either completely switched on or off (install) or at least activated / deactivated.
For me this checkbox has none of the mentioned effects.
The profiles work nevertheless, as said, with an activated profile extensions can be installed and uninstalled, the profiles can then be switched, and a profiles extension states get properly restored when reselected.
However, the view with these checkboxes seems largely pointless to me at the moment.
So my question is: what is their purpose?
Should their purpose be what I suspected, and the feature just isn't "ready" yet?
The checkboxes are for exporting the profile without including undesired configuration options. For example, the "UI State" option will save the currently open menus and submenus as a part of the profile's configuration, which you likely don't really want in most cases.
Notably, when I created a new blank profile and accessed this menu the only field present was the UI State, which implies that if a field is the same as the default configuration it won't be saved to the file.
When you export, you can name the profile and either save it locally as a ".code-profile" file, or upload it directly to GitHub as a gist. The file uses a syntax that I believe is unique, though it's very possible I just don't know it. It would be nice to have a simple JSON schema, but I'm sure the community is going to automate the hell out of this process within a few weeks/days.
I'm pretty sure the purpose of those checkboxes is to select whether or not each extension gets exported as part of the profile. Presumably they are all activated upon importing the profile and installing those profile extensions.

vscode setting for specific filename

I want to apply a setting for a specific file, the only answers I've seen for this topic have been language-specific settings. How can I achieve this?
At this time, you cannot achieve this natively. According to their documentation they state:
VS Code provides two different scopes for settings:
User Settings - Settings that apply globally to any instance of VS Code you open.
Workspace Settings - Settings stored inside your workspace and only apply when the workspace is opened.
You would have to file a feature request on their github for support

How to check built-in formatter/beautifier version? and does it auto-update?

Somebody from stackoverflow asked me to check if I have the latest js-beautify in my vscode. But I don't know how to check it. Can you please help?
I read from one of the threads in VS Code that it uses js-beautify as the formatter (it's the one doing the 'formatonsave' etc.). Please correct me if I'm wrong.
If it uses js-beautify, how do I know what version it is in? and does it auto-update to the latest version whenever there's a new one?
Thank you.
I already tried going through documentations and I also checked the preferences thoroughly, but I can't seem to find how to (manually) check for updates about plugins, especially the built-in ones like js-beautify.
The default setting for extensions.autoUpdate in VS Code enables auto-updating for all extensions. You can confirm this in your user settings or simply bring up the Command Palette (CTRL+SHIFT+P) and type 'auto update' to enable or disable it.
In the Command Palette you can also update extension mannually.
The current version of every installed extension is listed right next to its name in the extension panel or under the Changelog panel.

How do I disable telemetry for all users in Visual Studio Code?

I need to disable telemetry for Visual Studio code for all users. I have packaged the product in SCCM (specifically so its installed under the users profile so they can update it themselves).
I can't however figure out how to disable telemetry for all users.
I know individually the following needs to be added under the user's settings
{
"telemetry.enableCrashReporter": false,
"telemetry.enableTelemetry": false
}
Telemetry and data collection cannot be disabled in VSCode and the provided options to disable it is a red herring, see this answer for details. Essentially this is the same situation as with Windows 10 because, well, Microsoft.
As an alternative, you can use VSCodium but bear in mind 2 things:
Some extensions won't work.
Even if you hack them into work - they won't work properly or reliably (C# extension, for example, crashes, produces wrong results, etc.).
Since VSC is OpenSource, somebody took already care of that and provides a fork without telemetry:
https://vscodium.com/

How do you get #Recomended to work in VS Code?

I can get#recommended:workspace extensions to work correctly but I am unsure as to why I cannot get the general #recommended to show anything. Where am I supposed to put the extensions.json file?
My goal here is to have PowerShell install VSCode, copy over some JSON files for specific settings and then have the user shown the companies recommended extensions to install once they open up VSCode.
I know I can force them installed with code --install-extensions but I want the user to be able to pick and choose from the companies recommended list based on what kind of files they'll be working on. What I can't seem to figure out is how to get that list to show except within a workspace.
For example, we have a Chef team, an Azure team, Linux team, etc. each needing different extensions.
The #recommended option has no config. VS Code decides which extension to recommend based on the file types that exists in the folder/workspace that you opened (official release info).
So, in your scenario, I guess the best option is to use Workspace Recommendations (#recommended:workspace), using a different recommendation for each team/project.