Build one web project from a Solution with multiple web projects in Visual Studio Online Build Definition

后端 未结 3 785
甜味超标
甜味超标 2021-02-07 09:50

I\'m facing a problem where I need to build only one web project from a solution with two web projects in Visual Studio Online.

  • I have not found how to build only o
相关标签:
3条回答
  • 2021-02-07 10:27

    Instead of choosing the .sln file, you need to select the .proj file.

    Firstly, click the ellipsis button next to the Solution field.

    Then choose the .proj file you want to build. For example, the screenshot below shows that the build definition is configured to build the ClassLibrary1 project, instead of the whole solution (contains ClassLibrary1 and ClassLibrary4 project)

    0 讨论(0)
  • 2021-02-07 10:47

    You can add a new "Azure App Service Deploy" task to your build definition and set the "Package or folder field" to "$(build.artifactstagingdirectory)**\YOURPROJECT.zip"

    0 讨论(0)
  • 2021-02-07 10:47

    You may want to create a solution with just the web project that you want to build.

    In visual studio you can create a new project, and in that dialog select "other project types\solution".

    The new solution can sit right next to the existing one..

    0 讨论(0)
提交回复
热议问题