How do I reference instead of copy js files from a Nuget package at build time in TeamCity?

前端 未结 3 1898
迷失自我
迷失自我 2021-02-09 17:39

I\'ve got a packages.config file checked into source control. This specifies the exact version of the Nuget dependency I want. We have our own NuGet repository. We are creating

3条回答
  •  无人共我
    2021-02-09 18:29

    When a package is installed into a project, NuGet in fact performs these operations,

    1. Download the package file from source;
    2. Install the package into the so called packages folder, which is $(SolutionDir)\packages by default;
    3. Install the package into the project, which consists of adding references to DLLs, copying content files into the project directory etc.

    When a package is restored, only the first two steps are executed. Projects will not be touched by nuget package restore. Which is why the js files in your project will not be "restored".

    The only solution for now is to check in the js files in your project.

提交回复
热议问题