- Get VS2015 url from https://github.com/felixrieseberg/windows-build-tools/blob/master/src/constants.ts
- Save file into C:\vs_build_tools\windows-build-tools_vs2015\
- C:\vs_build_tools\windows-build-tools_vs2015\visualcppbuildtools_full.exe
- Open cmd prompt and run installer in offline-installer-builder mode (as per https://msdn.microsoft.com/en-us/library/mt706497.aspx)
cd /d C:\vs_build_tools\windows-build-tools_vs2015\
visualcppbuildtools_full.exe /layout C:\vs_build_tools\windows-build-tools_vs2015\offline\
Go into the layout directory
(C:\vs_build_tools\windows-build-tools_vs2015\offline\
in the above example)
and run the installer exe with the /NoRefresh
and /NoWeb
switches.
cd /d C:\vs_build_tools\windows-build-tools_vs2015\offline\
.\VisualCppBuildTools_Full.exe /NoRestart /S /L "C:\vs_build_tools\windows-build-tools_vs2015\build-tools-log\vs2015-build-tools.txt" /NoRefresh /NoWeb
VS2015 build tools install script doesn't modify the install https://github.com/felixrieseberg/windows-build-tools/blob/master/ps1/launch-installer.ps1#L39
- ./BuildTools_Full.exe /NoRestart /S /L "$BuildToolsInstallerPath\build-tools-log.txt"
/NoRestart
- Do not restart during or after installation./S
- Quiet mode with no display and no user interaction./L <filename>
- Specifies a location for the log file.
It may be possible to replace some of the install command line options with
an AdminDeployment.xml
file:
https://msdn.microsoft.com/en-us/library/ee225237.aspx
- Get VS2017 URL from https://github.com/felixrieseberg/windows-build-tools/blob/master/src/constants.ts
- Save file into C:\vs_build_tools\windows-build-tools_vs2017\
- C:\vs_build_tools\windows-build-tools_vs2017\vs_BuildTools.exe
- Open cmd prompt and run installer in offline-installer-builder mode (as per https://docs.microsoft.com/en-us/visualstudio/install/create-a-network-installation-of-visual-studio)
cd /d C:\vs_build_tools\windows-build-tools_vs2017\
visualcppbuildtools_full.exe --layout C:\vs_build_tools\windows-build-tools_vs2017\offline\ --add Microsoft.VisualStudio.Workload.VCTools
VS2017 build tools install script selects only the "Microsoft.VisualStudio.Workload.VCTools" package https://github.com/felixrieseberg/windows-build-tools/blob/master/ps1/launch-installer.ps1#L36
- ./vs_BuildTools.exe --norestart --quiet --add Microsoft.VisualStudio.Workload.VCTools
--norestart
- If present, commands with --passive or --quiet will not automatically restart the machine (if required). This is ignored if neither --passive nor --quiet are specified.--quiet
- If present, the command proceeds without UI. Progress messages are written to stdout and error messages are written to stderr. This option cannot be used with --passive.--add
- This defines an artifact (group, workload, or component) that is to be added to the installation. It can appear multiple times on the command line.
Visual Studio Build Tools currently offers both the VS2017 (14.1) and VS2015 (14.0) compilers. However, the Build Tools workload by default only installs VS2017. To use the Visual Studio Build Tools package with things that originally required the VS2015 build tools, the following additional components from the Microsoft.VisualStudio.Workload.VCTools
workload should be selected:
Microsoft.VisualStudio.Product.BuildTools
Microsoft.VisualStudio.Workload.VCTools
- Optional components:
Microsoft.VisualStudio.Component.VC.140
Microsoft.VisualStudio.Component.VC.ATL
Microsoft.VisualStudio.Component.VC.ATLMFC
Microsoft.VisualStudio.Component.Windows10SDK.14393
(latest supported by VS2015)Microsoft.VisualStudio.Component.Windows81SDK
- Optional components: