ocaml-dockerfile
ocaml-dockerfile copied to clipboard
Use winget to install or modify Visual Studio
Have a look at Use winget to install or modify Visual Studio:
You can use the Windows Package Manager "winget" tool to programmatically install, modify, or update Visual Studio on your machine along with other packages managed by winget.
I have used this before (see https://github.com/tarides/infrastructure/blob/791e0f8bb6ff5c8dd9e3f54122edcaa158087ec5/hopi.caelum.ci.dev/windows-desktops/roles/visual-studio/tasks/main.yml#L3) however, I found Chocolatey to be more reliable when running under Ansible.
I noticed that we jump through a lot of hoops to install WinGet on Windows Server Core, where it isn't actually supported. Then, we only use it to install Git. I wondered if we could actually dispense with WinGet altogether and just use the Git installer.
The idea was to use WinGet to install other things in the future, and to make sure we have one default package manager for Windows things. I'm not surprised that another package manager would be more reliable.
IIRC I needed to build WinGet to disable its telemetry, but it can now be disabled via its settings.