C# .NET使用vs代码构建多个项目

C# .NET使用vs代码构建多个项目,c#,.net,macos,visual-studio-code,C#,.net,Macos,Visual Studio Code,我正在尝试设置VisualStudio代码,以便在运行时构建多个dotnet项目 My task.json: { "version": "0.1.0", "command": "dotnet", "isShellCommand": true, "args": [], "tasks": [ { "taskName": "build_task", "suppressTaskName": true,

我正在尝试设置VisualStudio代码,以便在运行时构建多个dotnet项目

My task.json:

{
    "version": "0.1.0",
    "command": "dotnet",
    "isShellCommand": true,
    "args": [],
    "tasks": [
        {
            "taskName": "build_task",
            "suppressTaskName": true,
            "args": [
                "build", "${workspaceRoot}/main/project.json", "-o", "${workspaceRoot}/obj/", "--framework", "netcoreapp1.1"
            ],
            "isBuildCommand": true,
            "problemMatcher": "$msCompile"
        }
    ]
}
这很有效。但当我补充这一点时:

{
    "version": "0.1.0",
    "command": "dotnet",
    "isShellCommand": true,
    "args": [],
    "tasks": [
        {
            "taskName": "build_task",
            "suppressTaskName": true,
            "args": [
                "build", 
                "-o", "${workspaceRoot}/obj/",
                "${workspaceRoot}/main/project.json", "-f", "netcoreapp1.1",
                "${workspaceRoot}/pluginSample/project.json", "-f", "netstandard1.6"
            ],
            "isBuildCommand": true,
            "problemMatcher": "$msCompile"
        }
    ]
}
我得到这个错误:

Unexpected value 'netstandard1.6' for option 'framework'
但当我手动编译它时,它可以工作:

dotnet build -f netstandard1.6