Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions cmd/podman/common/build.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import (
"errors"
"fmt"
"io"
"maps"
"os"
"path/filepath"
"strconv"
Expand Down Expand Up @@ -337,9 +338,7 @@ func buildFlagsWrapperToOptions(c *cobra.Command, contextDir string, flags *Buil
if err != nil {
return nil, err
}
for name, val := range fargs {
args[name] = val
}
maps.Copy(args, fargs)
}
}
if c.Flag("build-arg").Changed {
Expand Down
4 changes: 2 additions & 2 deletions cmd/podman/common/completion.go
Original file line number Diff line number Diff line change
Expand Up @@ -1365,7 +1365,7 @@ func convertFormatSuggestions(suggestions []formatSuggestion) []string {
// This function will only work for pointer to structs other types are not supported.
// When "{{." is typed the field and method names of the given struct will be completed.
// This also works recursive for nested structs.
func AutocompleteFormat(o interface{}) func(cmd *cobra.Command, args []string, toComplete string) ([]string, cobra.ShellCompDirective) {
func AutocompleteFormat(o any) func(cmd *cobra.Command, args []string, toComplete string) ([]string, cobra.ShellCompDirective) {
// this function provides shell completion for go templates
return func(cmd *cobra.Command, args []string, toComplete string) ([]string, cobra.ShellCompDirective) {
// autocomplete json when nothing or json is typed
Expand Down Expand Up @@ -1454,7 +1454,7 @@ func AutocompleteFormat(o interface{}) func(cmd *cobra.Command, args []string, t
}
}

func getEntityType(cmd *cobra.Command, args []string, o interface{}) interface{} {
func getEntityType(cmd *cobra.Command, args []string, o any) any {
// container logic
if containers, _ := getContainers(cmd, args[0], completeDefault); len(containers) > 0 {
return &define.InspectContainerData{}
Expand Down
3 changes: 1 addition & 2 deletions cmd/podman/containers/port.go
Original file line number Diff line number Diff line change
Expand Up @@ -125,8 +125,7 @@ func port(_ *cobra.Command, args []string) error {
if hostIP == "" {
hostIP = "0.0.0.0"
}
protocols := strings.Split(v.Protocol, ",")
for _, protocol := range protocols {
for protocol := range strings.SplitSeq(v.Protocol, ",") {
// If not searching by port or port/proto, then dump what we see
if port == "" {
for i := uint16(0); i < v.Range; i++ {
Expand Down
2 changes: 1 addition & 1 deletion cmd/podman/images/search.go
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@ func imageSearch(cmd *cobra.Command, args []string) error {
return rpt.Execute(searchReport)
}

func printArbitraryJSON(v interface{}) error {
func printArbitraryJSON(v any) error {
prettyJSON, err := json.MarshalIndent(v, "", " ")
if err != nil {
return err
Expand Down
8 changes: 4 additions & 4 deletions cmd/podman/inspect/inspect.go
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ func newInspector(options entities.InspectOptions) (*inspector, error) {
// inspect inspects the specified container/image names or IDs.
func (i *inspector) inspect(namesOrIDs []string) error {
// data - dumping place for inspection results.
var data []interface{}
var data []any
var errs []error
ctx := context.Background()

Expand Down Expand Up @@ -157,7 +157,7 @@ func (i *inspector) inspect(namesOrIDs []string) error {
}
// Always print an empty array
if data == nil {
data = []interface{}{}
data = []any{}
}

var err error
Expand Down Expand Up @@ -191,8 +191,8 @@ func (i *inspector) inspect(namesOrIDs []string) error {
return nil
}

func (i *inspector) inspectAll(ctx context.Context, namesOrIDs []string) ([]interface{}, []error, error) {
var data []interface{}
func (i *inspector) inspectAll(ctx context.Context, namesOrIDs []string) ([]any, []error, error) {
var data []any
allErrs := []error{}
for _, name := range namesOrIDs {
ctrData, errs, err := i.containerEngine.ContainerInspect(ctx, []string{name}, i.options)
Expand Down
2 changes: 1 addition & 1 deletion cmd/podman/machine/client9p.go
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ func client9p(portNum uint32, mountPath string) error {
conn *vsock.Conn
retries = 20
)
for i := 0; i < retries; i++ {
for range retries {
// Host connects to non-hypervisor processes on the host running the VM.
conn, err = vsock.Dial(vsock.Host, portNum, nil)
// If errors.Is worked on this error, we could detect non-timeout errors.
Expand Down
8 changes: 4 additions & 4 deletions cmd/podman/machine/os/manager.go
Original file line number Diff line number Diff line change
Expand Up @@ -89,11 +89,11 @@ func GetDistribution() Distribution {

l := bufio.NewScanner(f)
for l.Scan() {
if strings.HasPrefix(l.Text(), "ID=") {
dist.Name = strings.TrimPrefix(l.Text(), "ID=")
if after, ok := strings.CutPrefix(l.Text(), "ID="); ok {
dist.Name = after
}
if strings.HasPrefix(l.Text(), "VARIANT_ID=") {
dist.Variant = strings.Trim(strings.TrimPrefix(l.Text(), "VARIANT_ID="), "\"")
if after, ok := strings.CutPrefix(l.Text(), "VARIANT_ID="); ok {
dist.Variant = strings.Trim(after, "\"")
}
}
return dist
Expand Down
4 changes: 2 additions & 2 deletions cmd/podman/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,10 @@ import (

type logrusLogger struct{}

func (l logrusLogger) Errorf(format string, args ...interface{}) {
func (l logrusLogger) Errorf(format string, args ...any) {
logrus.Errorf(format, args...)
}
func (l logrusLogger) Debugf(format string, args ...interface{}) {
func (l logrusLogger) Debugf(format string, args ...any) {
logrus.Debugf(format, args...)
}

Expand Down
3 changes: 1 addition & 2 deletions cmd/podman/parse/net.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,7 @@ func ValidateExtraHost(val string) (string, error) {
}

// Split the hostnames by semicolon and validate each one
nameList := strings.Split(names, ";")
for _, name := range nameList {
for name := range strings.SplitSeq(names, ";") {
if len(name) == 0 {
return "", fmt.Errorf("hostname in add-host %q is empty", val)
}
Expand Down
4 changes: 2 additions & 2 deletions cmd/podman/quadlet/quadlet.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@ import (
// logrusLogger implements the logiface.Logger interface using logrus
type logrusLogger struct{}

func (l logrusLogger) Errorf(format string, args ...interface{}) {
func (l logrusLogger) Errorf(format string, args ...any) {
logrus.Errorf(format, args...)
}

func (l logrusLogger) Debugf(format string, args ...interface{}) {
func (l logrusLogger) Debugf(format string, args ...any) {
logrus.Debugf(format, args...)
}

Expand Down
11 changes: 3 additions & 8 deletions cmd/podman/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import (
"path/filepath"
"runtime"
"runtime/pprof"
"slices"
"strconv"
"strings"

Expand Down Expand Up @@ -444,21 +445,15 @@ func configHook() {
}

func loggingHook() {
var found bool
if debug {
if logLevel != defaultLogLevel {
fmt.Fprintf(os.Stderr, "Setting --log-level and --debug is not allowed\n")
os.Exit(1)
}
logLevel = "debug"
}
for _, l := range common.LogLevels {
if l == strings.ToLower(logLevel) {
found = true
break
}
}
if !found {

if !slices.Contains(common.LogLevels, strings.ToLower(logLevel)) {
fmt.Fprintf(os.Stderr, "Log Level %q is not supported, choose from: %s\n", logLevel, strings.Join(common.LogLevels, ", "))
os.Exit(1)
}
Expand Down
2 changes: 1 addition & 1 deletion cmd/podman/system/df.go
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ func printVerbose(cmd *cobra.Command, reports *entities.SystemDfReport) error {
return writeTemplate(rpt, hdrs, dfVolumes)
}

func writeTemplate(rpt *report.Formatter, hdrs []map[string]string, output interface{}) error {
func writeTemplate(rpt *report.Formatter, hdrs []map[string]string, output any) error {
if rpt.RenderHeaders {
if err := rpt.Execute(hdrs); err != nil {
return err
Expand Down
2 changes: 1 addition & 1 deletion cmd/podman/utils/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ func RemoveSlash(input []string) []string {
return output
}

func PrintGenericJSON(data interface{}) error {
func PrintGenericJSON(data any) error {
enc := json.NewEncoder(os.Stdout)
// by default, json marshallers will force utf=8 from
// a string.
Expand Down
9 changes: 4 additions & 5 deletions cmd/podman/validate/choice.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package validate

import (
"fmt"
"slices"
"strings"
)

Expand Down Expand Up @@ -29,11 +30,9 @@ func (c *ChoiceValue) String() string {
}

func (c *ChoiceValue) Set(value string) error {
for _, v := range c.choices {
if v == value {
*c.value = value
return nil
}
if slices.Contains(c.choices, value) {
*c.value = value
return nil
}
return fmt.Errorf("%q is not a valid value. Choose from: %q", value, c.Choices())
}
Expand Down
8 changes: 4 additions & 4 deletions cmd/quadlet/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ func logToKmsg(s string) bool {
return true
}

func Logf(format string, a ...interface{}) {
func Logf(format string, a ...any) {
s := fmt.Sprintf(format, a...)
line := fmt.Sprintf("quadlet-generator[%d]: %s", os.Getpid(), s)

Expand All @@ -84,7 +84,7 @@ func enableDebug() {
debugEnabled = true
}

func Debugf(format string, a ...interface{}) {
func Debugf(format string, a ...any) {
if debugEnabled {
Logf(format, a...)
}
Expand Down Expand Up @@ -421,11 +421,11 @@ func generateUnitsInfoMap(units []*parser.UnitFile) map[string]*quadlet.UnitInfo
// quadletLogger implements the logiface.Logger interface using quadlet's custom logging
type quadletLogger struct{}

func (l quadletLogger) Errorf(format string, args ...interface{}) {
func (l quadletLogger) Errorf(format string, args ...any) {
Logf(format, args...)
}

func (l quadletLogger) Debugf(format string, args ...interface{}) {
func (l quadletLogger) Debugf(format string, args ...any) {
Debugf(format, args...)
}

Expand Down
3 changes: 1 addition & 2 deletions cmd/rootlessport/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -294,8 +294,7 @@ func handler(ctx context.Context, conn io.Reader, pm rkport.Manager) error {
func exposePorts(pm rkport.Manager, portMappings []types.PortMapping, childIP string) error {
ctx := context.TODO()
for _, port := range portMappings {
protocols := strings.Split(port.Protocol, ",")
for _, protocol := range protocols {
for protocol := range strings.SplitSeq(port.Protocol, ",") {
hostIP := port.HostIP
if hostIP == "" {
hostIP = "0.0.0.0"
Expand Down
4 changes: 2 additions & 2 deletions cmd/winpath/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ func addPathToRegistry(dir string) error {
}

// Is this directory already on the windows path?
for _, element := range strings.Split(existing, ";") {
for element := range strings.SplitSeq(existing, ";") {
if strings.EqualFold(element, dir) {
// Path already added
return nil
Expand Down Expand Up @@ -147,7 +147,7 @@ func removePathFromRegistry(path string) error {
// No point preallocating we can't know how big the array needs to be.
//nolint:prealloc
var elements []string
for _, element := range strings.Split(existing, ";") {
for element := range strings.SplitSeq(existing, ";") {
if strings.EqualFold(element, path) {
continue
}
Expand Down
14 changes: 7 additions & 7 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module github.com/containers/podman/v5
// Warning: if there is a "toolchain" directive anywhere in this file (and most of the
// time there shouldn't be), its version must be an exact match to the "go" directive.

go 1.23.3
go 1.24.0

require (
github.com/Microsoft/go-winio v0.6.2
Expand Down Expand Up @@ -68,11 +68,11 @@ require (
go.podman.io/common v0.65.0
go.podman.io/image/v5 v5.37.0
go.podman.io/storage v1.60.0
golang.org/x/crypto v0.41.0
golang.org/x/net v0.43.0
golang.org/x/sync v0.16.0
golang.org/x/sys v0.35.0
golang.org/x/term v0.34.0
golang.org/x/crypto v0.42.0
golang.org/x/net v0.44.0
golang.org/x/sync v0.17.0
golang.org/x/sys v0.36.0
golang.org/x/term v0.35.0
google.golang.org/protobuf v1.36.9
gopkg.in/inf.v0 v0.9.1
gopkg.in/yaml.v3 v3.0.1
Expand Down Expand Up @@ -183,7 +183,7 @@ require (
go.yaml.in/yaml/v3 v3.0.4 // indirect
golang.org/x/mod v0.27.0 // indirect
golang.org/x/oauth2 v0.30.0 // indirect
golang.org/x/text v0.28.0 // indirect
golang.org/x/text v0.29.0 // indirect
golang.org/x/time v0.11.0 // indirect
golang.org/x/tools v0.36.0 // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20250303144028-a0af3efb3deb // indirect
Expand Down
24 changes: 12 additions & 12 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -470,8 +470,8 @@ golang.org/x/crypto v0.19.0/go.mod h1:Iy9bg/ha4yyC70EfRS8jz+B6ybOBKMaSxLj6P6oBDf
golang.org/x/crypto v0.23.0/go.mod h1:CKFgDieR+mRhux2Lsu27y0fO304Db0wZe70UKqHu0v8=
golang.org/x/crypto v0.30.0/go.mod h1:kDsLvtWBEx7MV9tJOj9bnXsPbxwJQ6csT/x4KIN4Ssk=
golang.org/x/crypto v0.31.0/go.mod h1:kDsLvtWBEx7MV9tJOj9bnXsPbxwJQ6csT/x4KIN4Ssk=
golang.org/x/crypto v0.41.0 h1:WKYxWedPGCTVVl5+WHSSrOBT0O8lx32+zxmHxijgXp4=
golang.org/x/crypto v0.41.0/go.mod h1:pO5AFd7FA68rFak7rOAGVuygIISepHftHnr8dr6+sUc=
golang.org/x/crypto v0.42.0 h1:chiH31gIWm57EkTXpwnqf8qeuMUi0yekh6mT2AvFlqI=
golang.org/x/crypto v0.42.0/go.mod h1:4+rDnOTJhQCx2q7/j6rAN5XDw8kPjeaXEUR2eL94ix8=
golang.org/x/exp v0.0.0-20250408133849-7e4ce0ab07d0 h1:R84qjqJb5nVJMxqWYb3np9L5ZsaDtB+a39EqjV0JSUM=
golang.org/x/exp v0.0.0-20250408133849-7e4ce0ab07d0/go.mod h1:S9Xr4PYopiDyqSyp5NjCrhFrqg6A5zA2E/iPHPhqnS8=
golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
Expand All @@ -496,8 +496,8 @@ golang.org/x/net v0.10.0/go.mod h1:0qNGK6F8kojg2nk9dLZ2mShWaEBan6FAoqfSigmmuDg=
golang.org/x/net v0.15.0/go.mod h1:idbUs1IY1+zTqbi8yxTbhexhEEk5ur9LInksu6HrEpk=
golang.org/x/net v0.21.0/go.mod h1:bIjVDfnllIU7BJ2DNgfnXvpSvtn8VRwhlsaeUTyUS44=
golang.org/x/net v0.25.0/go.mod h1:JkAGAh7GEvH74S6FOH42FLoXpXbE/aqXSrIQjXgsiwM=
golang.org/x/net v0.43.0 h1:lat02VYK2j4aLzMzecihNvTlJNQUq316m2Mr9rnM6YE=
golang.org/x/net v0.43.0/go.mod h1:vhO1fvI4dGsIjh73sWfUVjj3N7CA9WkKJNQm2svM6Jg=
golang.org/x/net v0.44.0 h1:evd8IRDyfNBMBTTY5XRF1vaZlD+EmWx6x8PkhR04H/I=
golang.org/x/net v0.44.0/go.mod h1:ECOoLqd5U3Lhyeyo/QDCEVQ4sNgYsqvCZ722XogGieY=
golang.org/x/oauth2 v0.30.0 h1:dnDm7JmhM45NNpd8FDDeLhK6FwqbOf4MLCM9zb1BOHI=
golang.org/x/oauth2 v0.30.0/go.mod h1:B++QgG3ZKulg6sRPGD/mqlHQs5rB3Ml9erfeDY7xKlU=
golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
Expand All @@ -510,8 +510,8 @@ golang.org/x/sync v0.3.0/go.mod h1:FU7BRWz2tNW+3quACPkgCx/L+uEAv1htQ0V83Z9Rj+Y=
golang.org/x/sync v0.6.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk=
golang.org/x/sync v0.7.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk=
golang.org/x/sync v0.10.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk=
golang.org/x/sync v0.16.0 h1:ycBJEhp9p4vXvUZNszeOq0kGTPghopOL8q0fq3vstxw=
golang.org/x/sync v0.16.0/go.mod h1:1dzgHSNfp02xaA81J2MS99Qcpr2w7fw1gpm99rleRqA=
golang.org/x/sync v0.17.0 h1:l60nONMj9l5drqw6jlhIELNv9I0A4OFgRsG9k2oT9Ug=
golang.org/x/sync v0.17.0/go.mod h1:9KTHXmSnoGruLpwFjVSX0lNNA75CykiMECbovNTZqGI=
golang.org/x/sys v0.0.0-20181122145206-62eef0e2fa9b/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
Expand All @@ -537,8 +537,8 @@ golang.org/x/sys v0.12.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.17.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
golang.org/x/sys v0.20.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
golang.org/x/sys v0.28.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
golang.org/x/sys v0.35.0 h1:vz1N37gP5bs89s7He8XuIYXpyY0+QlsKmzipCbUtyxI=
golang.org/x/sys v0.35.0/go.mod h1:BJP2sWEmIv4KK5OTEluFJCKSidICx8ciO85XgH3Ak8k=
golang.org/x/sys v0.36.0 h1:KVRy2GtZBrk1cBYA7MKu5bEZFxQk4NIDV6RLVcC8o0k=
golang.org/x/sys v0.36.0/go.mod h1:OgkHotnGiDImocRcuBABYBEXf8A9a87e/uXjp9XT3ks=
golang.org/x/telemetry v0.0.0-20240228155512-f48c80bd79b2/go.mod h1:TeRTkGYfJXctD9OcfyVLyj2J3IxLnKwHJR8f4D8a3YE=
golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8=
Expand All @@ -548,8 +548,8 @@ golang.org/x/term v0.12.0/go.mod h1:owVbMEjm3cBLCHdkQu9b1opXd4ETQWc3BhuQGKgXgvU=
golang.org/x/term v0.17.0/go.mod h1:lLRBjIVuehSbZlaOtGMbcMncT+aqLLLmKrsjNrUguwk=
golang.org/x/term v0.20.0/go.mod h1:8UkIAJTvZgivsXaD6/pH6U9ecQzZ45awqEOzuCvwpFY=
golang.org/x/term v0.27.0/go.mod h1:iMsnZpn0cago0GOrHO2+Y7u7JPn5AylBrcoWkElMTSM=
golang.org/x/term v0.34.0 h1:O/2T7POpk0ZZ7MAzMeWFSg6S5IpWd/RXDlM9hgM3DR4=
golang.org/x/term v0.34.0/go.mod h1:5jC53AEywhIVebHgPVeg0mj8OD3VO9OzclacVrqpaAw=
golang.org/x/term v0.35.0 h1:bZBVKBudEyhRcajGcNc3jIfWPqV4y/Kt2XcoigOWtDQ=
golang.org/x/term v0.35.0/go.mod h1:TPGtkTLesOwf2DE8CgVYiZinHAOuy5AYUYT1lENIZnA=
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ=
Expand All @@ -559,8 +559,8 @@ golang.org/x/text v0.13.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE=
golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU=
golang.org/x/text v0.15.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU=
golang.org/x/text v0.21.0/go.mod h1:4IBbMaMmOPCJ8SecivzSH54+73PCFmPWxNTLm+vZkEQ=
golang.org/x/text v0.28.0 h1:rhazDwis8INMIwQ4tpjLDzUhx6RlXqZNPEM0huQojng=
golang.org/x/text v0.28.0/go.mod h1:U8nCwOR8jO/marOQ0QbDiOngZVEBB7MAiitBuMjXiNU=
golang.org/x/text v0.29.0 h1:1neNs90w9YzJ9BocxfsQNHKuAT4pkghyXc4nhZ6sJvk=
golang.org/x/text v0.29.0/go.mod h1:7MhJOA9CD2qZyOKYazxdYMF85OwPdEr9jTtBpO7ydH4=
golang.org/x/time v0.11.0 h1:/bpjEDfN9tkoN/ryeYHnv5hcMlc8ncjMcM4XBk5NWV0=
golang.org/x/time v0.11.0/go.mod h1:CDIdPxbZBQxdj6cxyCIdrNogrJKMJ7pr37NYpMcMDSg=
golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
Expand Down
2 changes: 1 addition & 1 deletion hack/podman-registry-go/registry.go
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ func StartWithOptions(options *Options) (*Registry, error) {

// Parse the output.
registry := Registry{}
for _, s := range strings.Split(out, "\n") {
for s := range strings.SplitSeq(out, "\n") {
if s == "" {
continue
}
Expand Down
2 changes: 1 addition & 1 deletion hack/podman-registry-go/registry_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ func TestStartAndStopMultipleRegistries(t *testing.T) {

// Start registries.
var errors *multierror.Error
for i := 0; i < 3; i++ {
for range 3 {
reg, err := StartWithOptions(registryOptions)
if err != nil {
errors = multierror.Append(errors, err)
Expand Down
Loading