Fix version detection, use <PackageVersion> if exists, then <Version>
ln.build - build0.l--n.de build job pending Details

master
Harald Wolff 2021-07-10 02:12:04 +02:00
parent 833890438f
commit e2a6124707
1 changed files with 1 additions and 1 deletions

View File

@ -29,7 +29,7 @@ namespace ln.build.support.dotnet
{
XmlDocument projectFile = new XmlDocument();
projectFile.Load(FileName);
XmlNode nodeVersion = projectFile.SelectSingleNode("Project/PropertyGroup/Version");
XmlNode nodeVersion = projectFile.SelectSingleNode("Project/PropertyGroup/PackageVersion") ?? projectFile.SelectSingleNode("Project/PropertyGroup/Version");
return (nodeVersion == null) ? null : SemVersion.Parse(nodeVersion.InnerText);
}