Fix NVR regex

This commit is contained in:
Mustafa Gezen 2022-05-10 16:32:31 +02:00
parent e889daa21f
commit 6df2fe1e3f
1 changed files with 1 additions and 1 deletions

View File

@ -3,7 +3,7 @@ package rpmutils
import "regexp"
var (
Nvr = regexp.MustCompile("^(\\S+)-([\\w~%.]+)-(\\w+(?:\\.[\\w+]+)+?)(?:\\.(\\w+))?(?:\\.rpm)?$")
Nvr = regexp.MustCompile("^(\\S+)-([\\w~%.+]+)-(\\w+(?:\\.[\\w+]+)+?)(?:\\.(\\w+))?(?:\\.rpm)?$")
epoch = regexp.MustCompile("(\\d+):")
module = regexp.MustCompile("^(.+)-(.+)-([0-9]{19})\\.((?:.+){8})$")
dist = regexp.MustCompile("(\\.el\\d(?:_\\d|))")