diff --git a/ImageSharp.sln b/ImageSharp.sln index c4abf1ae0..3164a389e 100644 --- a/ImageSharp.sln +++ b/ImageSharp.sln @@ -11,19 +11,17 @@ Project("{8BB2217D-0F2D-49D1-97BC-3654ED321F3B}") = "ImageSharp.Benchmarks", "te EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "SolutionItems", "SolutionItems", "{C317F1B1-D75E-4C6D-83EB-80367343E0D7}" ProjectSection(SolutionItems) = preProject + .editorconfig = .editorconfig .travis.yml = .travis.yml - build\appveyor-project-version-patch.js = build\appveyor-project-version-patch.js - build\appveyor-semver.ps1 = build\appveyor-semver.ps1 appveyor.yml = appveyor.yml CodeCoverage.runsettings = CodeCoverage.runsettings contributing.md = contributing.md - build\dotnet-latest.ps1 = build\dotnet-latest.ps1 + dotnet-latest.ps1 = dotnet-latest.ps1 features.md = features.md global.json = global.json ImageSharp.ruleset = ImageSharp.ruleset ImageSharp.sln.DotSettings = ImageSharp.sln.DotSettings NuGet.config = NuGet.config - build\package.json = build\package.json README.md = README.md Rebracer.xml = Rebracer.xml Settings.StyleCop = Settings.StyleCop diff --git a/build/Program.cs b/build/Program.cs index cda3f6236..3ee87d7d5 100644 --- a/build/Program.cs +++ b/build/Program.cs @@ -250,8 +250,7 @@ namespace ConsoleApplication internal string CalculateVersionNumber(string branch) { var version = this.Version.ToFullString(); - - + if (this.commitCount == 1 && branch == "") //master only { if (this.Version.IsPrerelease) @@ -263,6 +262,7 @@ namespace ConsoleApplication //only 1 commit (the changing one) we will skip appending suffix return version; } + var rootSpecialVersion = ""; @@ -276,10 +276,14 @@ namespace ConsoleApplication { rootSpecialVersion = "-" + rootSpecialVersion; } - if (branch == "") + if (branch == "" && !this.Version.IsPrerelease) { branch = fallbackTag; } + if (branch.Length > 0) + { + branch = "-" + branch; + } var maxLength = 20; maxLength -= rootSpecialVersion.Length; @@ -288,8 +292,8 @@ namespace ConsoleApplication { branch = branch.Substring(0, maxLength); } - - return $"{version}{rootSpecialVersion}-{branch}-{this.commitCount:00000}"; + + return $"{version}{rootSpecialVersion}{branch}-{this.commitCount:00000}"; } } } diff --git a/build/project.json b/build/project.json index 4f13b397f..1075b8724 100644 --- a/build/project.json +++ b/build/project.json @@ -10,13 +10,7 @@ }, "frameworks": { "net46": { - //"dependencies": { - // "Microsoft.NETCore.App": { - // "type": "platform", - // "version": "1.0.0" - // } - //}, - //"imports": "dnxcore50" + // this is only a net46 app because of LibGit2Sharp once they have a version that works on coreclr we can shift over. } } }