Skip to content

Commit

Permalink
Fix for commented VERSION key in /etc/os-release file (lop-devops#333)
Browse files Browse the repository at this point in the history
Signed-off-by: Kowshik Jois B S <[email protected]>
  • Loading branch information
bskjois authored Jun 25, 2024
1 parent aa38266 commit e1f25cf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/helper.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ def get_dist():
dist = re.findall("ID=(\\S+)", line)[0]
except:
pass
elif line.startswith("VERSION="):
elif line.__contains__("VERSION="):
try:
line = line.replace('"', '')
dist_ver = re.findall("VERSION=(\\S+)", line)[0].lower().replace("-", ".")
Expand Down

0 comments on commit e1f25cf

Please sign in to comment.