aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJoe DeVivo <[email protected]>2015-07-12 07:45:18 -0700
committerJoe DeVivo <[email protected]>2015-07-12 07:45:18 -0700
commit8b36b290c0901a9da72275ed0a7b2616980ed0e1 (patch)
treea8d6d1321a0a51c1ffc98f152523f7ef92c9a215 /src
parent64df140e9f9550a4876ba8c228d3bea336517d6b (diff)
downloadrelx-8b36b290c0901a9da72275ed0a7b2616980ed0e1.tar.gz
relx-8b36b290c0901a9da72275ed0a7b2616980ed0e1.tar.bz2
relx-8b36b290c0901a9da72275ed0a7b2616980ed0e1.zip
Added {cmd, Cmd} to version attribute.
Whatever CMD returns will be the version number
Diffstat (limited to 'src')
-rw-r--r--src/rlx_config.erl3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/rlx_config.erl b/src/rlx_config.erl
index 1f441ed..0ee3543 100644
--- a/src/rlx_config.erl
+++ b/src/rlx_config.erl
@@ -299,5 +299,8 @@ parse_vsn(Vsn) when Vsn =:= semver ; Vsn =:= "semver" ->
parse_vsn({semver, Prefix}) ->
{ok, V} = ec_git_vsn:vsn({Prefix}),
V;
+parse_vsn({cmd, Command}) ->
+ V = os:cmd(Command),
+ V;
parse_vsn(Vsn) ->
Vsn.