ajoberstar / reckon

Infer a project's version from your Git repository.
Apache License 2.0
187 stars 28 forks source link

[Fug / Improvement] Please Improve error message on invalid passed reckon.scope #57

Closed childnode closed 6 years ago

childnode commented 6 years ago

since -Preckon.stage=sdf provides a helpful hint

* What went wrong:
> Stage "sdf" is not one of: [rc, final]

-Preckon.scope=sdf only provides message

> No enum constant org.ajoberstar.reckon.core.Scope.SDF

instead of expected

> Scope "sdf" is not one of: [patch, minor, major]
childnode commented 6 years ago

https://github.com/ajoberstar/reckon/blob/b23e2914fe6ed155a83cb9c4046174049b67fd55/reckon-core/src/main/java/org/ajoberstar/reckon/core/strategy/StagePreReleaseStrategy.java#L54 https://github.com/ajoberstar/reckon/blob/b23e2914fe6ed155a83cb9c4046174049b67fd55/reckon-core/src/main/java/org/ajoberstar/reckon/core/strategy/ScopeNormalStrategy.java#L40

ajoberstar commented 6 years ago

Agreed. Thanks for pointing this out!