carvel-dev / carvel-dev/ytt

Add version compare lib/func

Open
#705 2 comments 2 reactions 0 assignees View on GitHub
enhancement priority/unprioritized-backlog
Dominant language
Go
Stars
1.9k
Forks
167
PR merge metrics
No merged PRs in 30d

Description

**Describe the problem/challenge you have**
I managed to get K8s version and store it in a variable, want to check whether there is some handy lib that can compare version

**Describe the solution you'd like**
maybe a new func from version module:
```
def compare_version (a, b):
// return 1 if version a > b
// return 0 if version a <= b
// a could be v1.23.1
// b could be v1.22.1
enf
```

**Anything else you would like to add:**
[Additional information that will assist in solving the issue.]

---
Vote on this request

This is an invitation to the community to vote on issues, to help us prioritize our backlog. Use the "smiley face" up to the right of this comment to vote.

👍 "I would like to see this addressed as soon as possible"
👎 "There are other more important things to focus on right now"

We are also happy to receive and review Pull Requests if you want to help working on this issue.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.