properly strip the version based on whether it's a RC or not
This commit is contained in:
parent
01ea78c10e
commit
fa5f58c086
|
@ -63,9 +63,14 @@ func VersionStr() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
func VersionStrip() string {
|
func VersionStrip() string {
|
||||||
|
if strings.Contains(Version, "~") {
|
||||||
|
//This is a RC
|
||||||
version := strings.Split(Version, "~")
|
version := strings.Split(Version, "~")
|
||||||
return version[0]
|
return version[0]
|
||||||
}
|
}
|
||||||
|
version := strings.Split(Version, "-")
|
||||||
|
return version[0]
|
||||||
|
}
|
||||||
|
|
||||||
func Statisfies(strvers string, constraint string) (bool, error) {
|
func Statisfies(strvers string, constraint string) (bool, error) {
|
||||||
vers, err := version.NewVersion(strvers)
|
vers, err := version.NewVersion(strvers)
|
||||||
|
|
Loading…
Reference in a new issue