Update module github.com/openshift/imagebuilder to v1.2.6

Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
This commit is contained in:
renovate[bot]
2024-02-24 17:16:24 +00:00
committed by GitHub
parent ea3221a862
commit 6089769026
42 changed files with 1679 additions and 407 deletions

View File

@@ -6,7 +6,6 @@ services:
- docker
go:
- "1.19"
- "1.20"
before_install:

View File

@@ -198,6 +198,21 @@ func (stages Stages) ByName(name string) (Stage, bool) {
return stage, true
}
}
if i, err := strconv.Atoi(name); err == nil {
return stages.ByPosition(i)
}
return Stage{}, false
}
func (stages Stages) ByPosition(position int) (Stage, bool) {
for _, stage := range stages {
// stage.Position is expected to be the same as the unnamed
// index variable for this loop, but comparing to the Position
// field's value is easier to explain
if stage.Position == position {
return stage, true
}
}
return Stage{}, false
}
@@ -211,6 +226,16 @@ func (stages Stages) ByTarget(target string) (Stages, bool) {
return stages[i : i+1], true
}
}
if position, err := strconv.Atoi(target); err == nil {
for i, stage := range stages {
// stage.Position is expected to be the same as the unnamed
// index variable for this loop, but comparing to the Position
// field's value is easier to explain
if stage.Position == position {
return stages[i : i+1], true
}
}
}
return nil, false
}
@@ -224,6 +249,16 @@ func (stages Stages) ThroughTarget(target string) (Stages, bool) {
return stages[0 : i+1], true
}
}
if position, err := strconv.Atoi(target); err == nil {
for i, stage := range stages {
// stage.Position is expected to be the same as the unnamed
// index variable for this loop, but comparing to the Position
// field's value is easier to explain
if stage.Position == position {
return stages[0 : i+1], true
}
}
}
return nil, false
}

View File

@@ -12,7 +12,7 @@
#
%global golang_version 1.8.1
%{!?version: %global version 1.2.6-dev}
%{!?version: %global version 1.2.6}
%{!?release: %global release 1}
%global package_name imagebuilder
%global product_name Container Image Builder