Build separately a web app backend in a Xamarin so

2019-07-14 09:35发布

Got a Xamarin solution which includes a project for a web app backend. Trying to set up a separate build definition for the web app backend so that it deploys to Azure app service. We have that API app folder inside the Xamarin solution folder.

When trying manual mapping to build the web app it fails as it tries to build the whole solution while it should only build that project as I used MSBuild task and pointed it to the csproj file in that folder.

How can we get that specific folder to build separately?

1条回答
▲ chillily
2楼-- · 2019-07-14 09:54

There are two ways to just build a project:

  1. Build solution with /t:[projectname] MSBuild arguments (e.g. Visual Studio Build step; Solution: *****.sln**; MSBuild Arguments: /t:ConsoleApplication1; Platform: $(BuildPlatform); Configuration: $(BuildConfiguration)))
  2. Specify the project file directly for Visual Studio Build or MSBuild step/task. (e.g. Visual Studio Build; Solution: [project file (csproj) path]; MSBuild Arguments: /p:OutputPath="bin\$(BuildConfiguration)\\" Platform: $(BuildPlatform); Configuration: $(BuildConfiguration))
查看更多
登录 后发表回答