Skip to content

Commit

Permalink
Update modules/manager/metadata/metadata.go
Browse files Browse the repository at this point in the history
Co-authored-by: Patryk Małek <[email protected]>
  • Loading branch information
programmer04 and pmalek committed Jul 1, 2024
1 parent d40639c commit e52740c
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions modules/manager/metadata/metadata.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,9 @@ type Info struct {
// UserAgent returns the User-Agent string to use in all HTTP requests made by KGO.
func (inf Info) UserAgent() string {
org := strings.ToLower(inf.Organization)
if inf.Flavor == OSSFlavor {
return fmt.Sprintf("%s-%s-%s/%s", org, inf.ProjectName, OSSFlavor, inf.Release)
}
return fmt.Sprintf("%s-%s/%s", org, inf.ProjectName, inf.Release)
return fmt.Sprintf("%s/%s (%s/%s) (%s)",
inf.ProjectName, inf.Release, runtime.GOOS, runtime.GOARCH, inf.Flavor,
)
}

var (
Expand Down

0 comments on commit e52740c

Please sign in to comment.