Skip to content

Commit

Permalink
get_release() - start naming .0 releases without cutting the number off
Browse files Browse the repository at this point in the history
  • Loading branch information
C0rn3j committed Jan 25, 2025
1 parent 06973c1 commit a18b826
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions scc/gui/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -1516,11 +1516,13 @@ def load_profile_selection(self):
def get_release(n:int = 4) -> str:
"""
Returns current version rounded to max. 'n' numbers.
( v0.14.1.3 ; n=3 -> v0.14.1 )
( v0.14.1.3 ; n=3 -> v0.14.1 )
( v0.14.0.0 ; n=3 -> v0.14.0.0 )
"""
split = DAEMON_VERSION.split(".")[0:n]
while split[-1] == "0":
split = split[0:len(split) - 1]
# Remove final zeroes ( v0.14.0.0 ; n=3 -> v0.14 ) - disabled, let's include them
#while split[-1] == "0":
# split = split[0:len(split) - 1]
return ".".join(split)


Expand Down

0 comments on commit a18b826

Please sign in to comment.