dotnet pack with /p:PackageVersion overrides package version of dependecies as well 路 Issue #12322 路 dotnet/sdk 路 GitHub 您所在的位置:网站首页 packageversion dotnet pack with /p:PackageVersion overrides package version of dependecies as well 路 Issue #12322 路 dotnet/sdk 路 GitHub

dotnet pack with /p:PackageVersion overrides package version of dependecies as well 路 Issue #12322 路 dotnet/sdk 路 GitHub

2024-02-29 05:05| 来源: 网络整理| 查看: 265

This is on SDK 3.1.301. I haven't tested it on the 5.0 previews. I have a solution with two .net core class libraries, LibA and LibB. LibB depends on LibA. Each of the csproj sets the package version for their corresponding library (LibA 2.0.0, LibB 1.0.0). When I run dotnet pack on LibB, the nupkg correctly lists LibA 2.0.0 as a dependecy. However if I run dotnet pack /p:PackageVersion=1.0.0-ci-20200702.1 on LibB the nupkg lists LibA 1.0.0-ci-20200702.1 as a dependency. The pack tool seems to be overriding the package version of all my project dependencies, not just the project I am building. Is this the intended behavior? I would think that the package version should only apply to the package I am building. Is there a way to tell dotnet pack to only override the version of the csproj on which it is being invoked and not its project dependencies?



【本文地址】

公司简介

联系我们

今日新闻

    推荐新闻

    专题文章
      CopyRight 2018-2019 实验室设备网 版权所有