Install Visual stdio 2017 offline

Install Visual stdio 2017 offline

Visual stdio 2017 has been out for a while and haven't had time to try installing it. A little time this weekend, I took a closer look at the offline installation of Visual stdio 2017.

This article mainly refers to Microsoft's official documents:

https://docs.microsoft.com/en-us/visualstudio/install/install-vs-inconsistent-quality-network

Students who are good in English can read the original text directly.

Unlike Visual stdio 2015, Microsoft does not provide ISO files for Visual stdio 2017. So we can't get the Visual stdio 2017 full installer through the official CD image. So the first step in offline installation is to download all the required files online first.

Same as online installation, first go to download a small installer:
https://www.visualstudio.com/downloads/

I only use the community edition, so I downloaded vs_Community.exe

Next, use vs_Community.exe to download the files we need to a directory so that we can install them offline later.

There are quite a few named line parameters for vs_Community.exe. For a detailed introduction, please refer to the following documents:

https://docs.microsoft.com/en-us/visualstudio/install/use-command-line-parameters-to-install-visual-studio

If we need to download all the content of VS2017, we can do this:

vs_community.exe --layout c:\vs2017layout --lang en-US

or

vs_community.exe --layout c:\vs2017layout --lang zh-CN

The above two commands correspond to the English and Chinese versions respectively.

The complete installation file of VS2017 is about 35GB, and it takes up 100GB of space to install on the computer, so before doing this, think about whether you really need such a complete VS2017.

For me, I only use VS2017 for C++ development, so I only choose to download the C++ related parts.

vs_community.exe --layout c:\vs2017layout --add Microsoft.VisualStudio.Workload.NativeDesktop --includeRecommended --lang en-US

If you are doing .NET web and .NET desktop development, then execute:

vs_community.exe --layout c:\vs2017layout --add Microsoft.VisualStudio.Workload.ManagedDesktop --add Microsoft.VisualStudio.Workload.NetWeb --add Component.GitHub.VisualStudio --includeOptional --lang en-US

If you are doing .NET desktop and Office development, then execute:

vs_community.exe --layout c:\vs2017layout --add Microsoft.VisualStudio.Workload.ManagedDesktop --add Microsoft.VisualStudio.Workload.Office --includeOptional --lang en-US

Then just wait, depending on the speed of the network and the content downloaded, it can be as many as tens of hours, or as few as tens of minutes.

After all the download is complete, you can install it. Note that the command line parameters used during installation are the same as those used during download. This will ensure that we have downloaded everything that will be installed. For example, I still take C++ development as an example, then the installation should be like this:

c:\vs2017layout\vs_community.exe --add Microsoft.VisualStudio.Workload.NativeDesktop --includeRecommended --lang en-US

If you are prompted that the signature is incorrect during installation, you must import the signature first. All signatures are in the certificates folder. Installing the signature is very simple, double-click one by one, and then follow the prompts.

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325561329&siteId=291194637