erlware / relx

Sane, simple release creation for Erlang
http://erlware.github.io/relx
Apache License 2.0
696 stars 233 forks source link

Make rlx_util:parse_vsn parse integer versions #913

Closed essen closed 2 years ago

essen commented 2 years ago

This allows using integer release versions "1", "2" and so on instead of semver, like was possible in Relx 3. In current main branch this only seems to be an issue when creating relups without providing the previous version, in that case the crash happens at https://github.com/erlware/relx/blob/main/src/rlx_relup.erl#L95

I have also changed the returned value 0 because it resulted in unhelpful crashes down the line because the code didn't expect an integer but a tuple.

Tested against Erlang.mk tests.

Original PR: https://github.com/erlware/relx/pull/911