20 lines
322 B
Go
20 lines
322 B
Go
package index
|
|
|
|
import "strings"
|
|
|
|
type repomd struct {
|
|
Locations []location `xml:"data>location"`
|
|
}
|
|
|
|
type location struct {
|
|
Href string `xml:"href,attr"`
|
|
}
|
|
|
|
func (r repomd) getFilelists() string {
|
|
for _, loc := range r.Locations {
|
|
if strings.Contains(loc.Href, "filelists.xml") {
|
|
return loc.Href
|
|
}
|
|
}
|
|
return ""
|
|
} |