tindzk / seed

Build tool for Scala projects
https://tindzk.github.io/seed/
Apache License 2.0
238 stars 13 forks source link

SemanticVersioning: Fix parsing of large pre-release versions #41

Closed tindzk closed 5 years ago

tindzk commented 5 years ago

When updating projects with the JGit dependency, the following exception is thrown:

Exception in thread "main" java.lang.NumberFormatException: For input string: "201202151440"
        at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)
        at java.lang.Integer.parseInt(Integer.java:583)
        at java.lang.Integer.parseInt(Integer.java:615)
        at scala.collection.immutable.StringLike.toInt(StringLike.scala:304)
        at scala.collection.immutable.StringLike.toInt$(StringLike.scala:304)
        at scala.collection.immutable.StringOps.toInt(StringOps.scala:33)
        at seed.artefact.SemanticVersioning$.parsePreReleaseParts(SemanticVersioning.scala:59)
        at seed.artefact.SemanticVersioning$.parseVersion(SemanticVersioning.scala:94)

Changes: