Skip to content

Commit

Permalink
Fix version ordering (#132)
Browse files Browse the repository at this point in the history
  • Loading branch information
ericof authored Mar 22, 2024
1 parent 0474963 commit 5bda46a
Show file tree
Hide file tree
Showing 3 changed files with 756 additions and 2 deletions.
3 changes: 3 additions & 0 deletions local_extensions/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
import requests
from cookiecutter.utils import simple_filter

from .semver import VersionInfo

REGISTRIES = {
"Docker Hub": "",
"GitHub": "ghcr.io/",
Expand Down Expand Up @@ -62,6 +64,7 @@ def latest_version(
version=v, min_version=min_version, max_version=max_version
)
],
key=lambda v: VersionInfo.parse(v.replace("v", "")),
reverse=True,
)
if not include_alphas:
Expand Down
Loading

0 comments on commit 5bda46a

Please sign in to comment.