Skip to content

Commit

Permalink
fix update detection
Browse files Browse the repository at this point in the history
  • Loading branch information
czoido committed Oct 23, 2024
1 parent aa82f4c commit 68c589a
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion conan/internal/api/detect/detect_vs.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,11 @@ def vs_detect_update(version):
version = {"194": "17", "193": "17", "192": "16", "191": "15"}.get(str(version))
full_version = _vs_installation_path(version)[1]
components = full_version.split(".")
# 17.10 --> 1940
# 17.11 --> 1941
# etc...
if len(components) > 1:
return components[1]
return str(int(components[1]) % 10)


def _vs_installation_path(version):
Expand Down

0 comments on commit 68c589a

Please sign in to comment.