Skip to content

Commit

Permalink
Fixes for new solution template
Browse files Browse the repository at this point in the history
  • Loading branch information
Noggog committed Sep 21, 2024
1 parent d4bf513 commit 8214b69
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Mutagen.Bethesda.Synthesis/Projects/CreateProject.cs
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public string[] Create(
sb.AppendLine("<Project Sdk=\"Microsoft.NET.Sdk\">");
sb.AppendLine($" <PropertyGroup>");
sb.AppendLine($" <OutputType>Exe</OutputType>");
sb.AppendLine($" <TargetFramework>{(targetFramework ?? "net6.0")}</TargetFramework>");
sb.AppendLine($" <TargetFramework>{(targetFramework ?? "net8.0")}</TargetFramework>");
sb.AppendLine($" <TargetPlatformIdentifier>Windows</TargetPlatformIdentifier>");
sb.AppendLine($" <ImplicitUsings>true</ImplicitUsings>");
sb.AppendLine($" </PropertyGroup>");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,11 @@ private string GetVersion(AssemblyVersions versions)
try
{
var version = versions.ProductVersion;
var plusIndex = version!.IndexOf("+", StringComparison.OrdinalIgnoreCase);
if (plusIndex != -1)
{
version = version.Substring(0, plusIndex);
}
return version!.TrimEnd(".0").TrimEnd(".0");
}
catch (Exception e)
Expand Down

0 comments on commit 8214b69

Please sign in to comment.