Skip to content

Commit

Permalink
SemVer Parse calculates the prerelease correctly when metadata is used.
Browse files Browse the repository at this point in the history
  • Loading branch information
zaptech\jun.zhu committed Apr 26, 2017
1 parent f75e9fc commit ecf5ccb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Paket.Core/SemVer.fs
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ module SemVer =
match firstDash, plusIndex with
| -1, _ -> ""
| d, p when p = -1 -> version.Substring(d+1)
| d, p -> version.Substring(d+1, (version.Length - 1 - p) )
| d, p -> version.Substring(d+1, (p - 1 - d) )

/// there can only be one piece of build metadata, and it is signified by a + and then any number of dot-separated alpha-numeric groups.
/// this just greedily takes the whole remaining string :(
Expand Down

0 comments on commit ecf5ccb

Please sign in to comment.