Appveyor似乎忽略了infomational版本

Leo*_*rev 5 nuget-package appveyor

我正在尝试通过AssemblyInformationalVersion对我的NuGet包进行版本控制,同时保持AssemblyVersion相同.我在.nuspec中使用tag $ version $.

但是,如果我使用appveyor构建NuGet,它会继续使用AssemblyVersion.

我的appveyor.yaml:

version: 1.0.{build}
pull_requests:
  do_not_increment_build_number: true
configuration: Release
assembly_info:
   patch: true
   file: '**\AssemblyInfo.*'
   assembly_file_version: '{version}'
   assembly_informational_version: '{version}'
before_build:
   nuget restore
build:
   publish_nuget: true
   parallel: true
   verbosity: minimal
deploy:
   provider: NuGet
   api_key: <SKIPPED>
Run Code Online (Sandbox Code Playgroud)

我的.nuspec摘录

<metadata>
 ....
    <version>$version$</version>
 ....
</metadata>
Run Code Online (Sandbox Code Playgroud)

UPD:我检查了信息版本正确设置为文件: 信息版

此外,我不知道它是否相关,但它似乎忽略了我的 <files>指令并把所有内容都放入lib而不是analyzers\dotnet\cs

Ily*_*eyn 2

如果AssemblyInfo.*文件不包含AssemblyInformational标签,这种情况经常发生。在这种情况下,AppVeyor 无需修补任何内容。