简体   繁体   中英

VS2017 .NetCore project and SDK

I have migrated my VS2015 project developed using .Net Core to VS 2017 and the migration went pretty well.

In my former VS2015 project, I used the global.json file to define which SDK to use for my project as below:

{
  "projects": [ "src", "test" ],
  "sdk": {
    "version": "1.0.0-preview2-003131"   
  }
}

How does it work now in 2017? I was not able to retrieve a similar configuration file where I could easily change the SDK version.

Thank you S.

VS 2017 carries its own copy of the needed MSBuild "SDK" (!= CLI package) and does not rely on a version of the CLI to be installed.

For CLI commands, the SDK version in global.json is still respected and chooses the version of the CLI to run, but you are less likely to need it because the msbuild based CLI is supposed to be backwards-compatible.

That being said, some problems may still arise if you have 2.0.0 daily builds installed and want to use them, VS might not be able to work with that projects - but it can be patched. See https://github.com/aspnet/Announcements/issues/231 .

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM