Skip to content

Commit

Permalink
Fixed project version
Browse files Browse the repository at this point in the history
  • Loading branch information
techbech committed Sep 24, 2024
1 parent 69c38a6 commit f9e5da4
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/wurf/waf_conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,9 @@ def project_version(ctx):
return None

commit = git.current_commit(cwd)
tag = ([None] + git.tags(cwd))[-1]
sorted_semver_tags = sorted(git.tags(cwd), key=lambda x: tuple(map(int, x.split(".")))
if all(map(str.isdigit, x.split("."))) else x)
tag = ([None] + sorted_semver_tags)[-1]
if tag is not None:
tag = tag.rstrip()
tag_commit = git.checkout_to_commit_id(cwd, tag)
Expand Down

0 comments on commit f9e5da4

Please sign in to comment.