首页
学习
活动
专区
工具
TVP
发布
社区首页 >问答首页 >AppVeyor的.NET核心.csproj修补没有任何影响

AppVeyor的.NET核心.csproj修补没有任何影响
EN

Stack Overflow用户
提问于 2018-09-23 18:29:42
回答 1查看 317关注 0票数 2

这个周末我开始玩AppVeyor了。在我解决了其他一些问题之后,我目前还停留在版本修补上。

我试图实现的目标:我的普通主分支应该像1.0.{build}这样的版本,它工作得很好。但是当涉及到开发分支时,每个构建(或者说nuget包)都应该包括类似于"-alpha“后缀的东西。

这是我当前的Appveyor.xml。它当前提交到我的dev-Branch的根目录,master分支当前没有xml,我想先修复这个问题。

代码语言:javascript
复制
version: 1.0.{build}
image: Visual Studio 2017
configuration: Release
platform: Any CPU
dotnet_csproj:
  patch: true
  file: '**\*.csproj'
  version: '{version}'
  package_version: '{version}'
  assembly_version: '{version}'
  file_version: '{build}'
  informational_version: '{version}'
before_build:
- cmd: dotnet restore Kinoheld.Api.Client\Kinoheld.Api.Client.sln
build:
  verbosity: minimal
after_build:
- cmd: dotnet pack Kinoheld.Api.Client\Kinoheld.Api.Client\Kinoheld.Api.Client.csproj
artifacts:
- path: '**\*.nupkg'
deploy: off

for:
-
  branches:
    only:
      - dev

  dotnet_csproj:
    patch: true
    file: '**\*.csproj'
    version: '{version}-alpha'
    package_version: '{version}-alpha'
    assembly_version: '{version}'
    file_version: '{version}'
    informational_version: '{version} (pre-release)'

为什么我的项目没有打补丁?好吧,我不知道它们是否真的没有补丁,但为什么最终的结果是我的dev-build包没有我上面指定的版本?我是不是漏掉了什么?也许在我的csproj文件或类似的东西中?

你可以在这里找到我的项目开发分支- https://github.com/janniksam/Kinoheld/tree/dev -随时查看它,如果你需要比上面的xml更多的信息。

更新:\

如果你想知道:I you not the "Ignore appveyor.yml“。我在控制台中看到行Patching .NET Core .csproj files

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2018-09-23 19:02:46

我终于找到了解决方案。当涉及到查找项目时,Appveyor会在项目中搜索属性<Version>。我的项目没有声明<Version>

票数 6
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/52465213

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档