1
0
Fork 0
forked from forgejo/forgejo

Support for grouping RPMs using paths (#26984)

The current rpm repository places all packages in the same repository,
and different systems (el7,f34) may hit packages that do not belong to
this distribution ( #25304 ) , which now supports grouping of rpm.

![图片](d1e1d99f-7799-4b2b-a19b-cb2a5c692914)

Fixes #25304 .
Fixes #27056 .

Refactor: [#25866](https://github.com/go-gitea/gitea/pull/25866)
This commit is contained in:
Exploding Dragon 2024-01-12 11:16:05 +08:00 committed by GitHub
parent 7c2f093e85
commit ba4d0b8ffb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 192 additions and 101 deletions

View file

@ -4,6 +4,7 @@
package templates
import (
"regexp"
"strings"
"code.gitea.io/gitea/modules/base"
@ -25,6 +26,10 @@ func (su *StringUtils) Contains(s, substr string) bool {
return strings.Contains(s, substr)
}
func (su *StringUtils) ReplaceAllStringRegex(s, regex, new string) string {
return regexp.MustCompile(regex).ReplaceAllString(s, new)
}
func (su *StringUtils) Split(s, sep string) []string {
return strings.Split(s, sep)
}