-
Notifications
You must be signed in to change notification settings - Fork 892
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
launch Visual Studio Installer to install the C++ tools #1462
Comments
I would be happy to accept a PR for this, although we'd need a fallback for detecting visual studio: I have VS2017 installed and |
To include the preview Visual Studio version, you must add $installationPath = & "${env:ProgramFiles(x86)}\Microsoft Visual Studio\Installer\vswhere.exe" -latest -property installationPath -prerelease
& "${env:ProgramFiles(x86)}\Microsoft Visual Studio\Installer\vs_installershell.exe" modify `
--installPath $installationPath `
--add Microsoft.VisualStudio.Component.VC.Tools.x86.x64 `
--add Microsoft.VisualStudio.Component.Windows10SDK |
An alternative to this is to add a {
"version": "1.0",
"components": [
"Microsoft.VisualStudio.Component.VC.Tools.x86.x64",
"Microsoft.VisualStudio.Component.Windows10SDK"
]
} |
Is there a safe and consistent way we can launch this from |
@rustbot label: +O-windows |
It turns out that the I exported my current config and I do not have the component installed. I think the required components are now: {
"version": "1.0",
"components": [
"Microsoft.VisualStudio.Component.VC.Tools.x86.x64",
"Microsoft.VisualStudio.Component.VC.Redist.14.Latest",
]
} If I save this to a You can see it select those two It would be great if someone could add a screenshot without them installed yet. |
Fixed by #2954. |
rust-init.exe
does a good job at detecting for missing C++ tools. It would be even better if it detected an existing Visual Studio installation to prompt with something like:Would you like to launch Visual Studio Installer to install the C++ tools?
and then do so.The scenario is that I have Visual Studio 2017 installed and I want to install Rust. Currently you get this prompt #1114 (comment) . It would be amazing if
rust-init.exe
launched the Visual Studio Installer to install the missing dependencies. Here is a PowerShell script that I ran as admin to get them installed:I took notes in ctaggart#1 while making this.
The text was updated successfully, but these errors were encountered: