tintoy / msbuild-project-tools-vscode

VS Code extension for MSBuild intellisense (including PackageReference completion).
MIT License
83 stars 17 forks source link

Adding a config setting that enables the user to specify / override additional MSBuild toolsets #47

Open tintoy opened 5 years ago

tintoy commented 5 years ago

Example config:

{
    "msbuildProjectTools.msbuild.toolsets": {
        "15.0": {
            "baseDirectory": "C:\\MyToolsetBaseDirectory",
            "globalPropertyOverrides": {
                "MyProperty": "SomeValue"
            }
        },
        "Current": {
            "baseDirectory": "C:\\AnotherToolsetBaseDirectory"
        }
}

MSBuild appends the toolset version to the base directory (e.g. 15.0 -> C:\MyToolsetBaseDirectory\15.0 or Current -> C:\AnotherToolsetBaseDirectory\Current) to find common.propsand.targetsfiles. If15.0orCurrent` toolset is specified, then this will (depending on .NET Core SDK version) override the default toolset configuration.

Relates to tintoy/msbuild-project-tools-vscode#46.