Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WIP] Removing Strategy.APIversion #2

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
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
10 changes: 4 additions & 6 deletions pkg/apis/build/v1beta1/build_conversion.go
Original file line number Diff line number Diff line change
Expand Up @@ -133,9 +133,8 @@ func (dest *BuildSpec) ConvertFrom(orig *v1alpha1.BuildSpec) error {

// Handle BuildSpec Strategy
dest.Strategy = Strategy{
Name: orig.StrategyName(),
Kind: (*BuildStrategyKind)(orig.Strategy.Kind),
APIVersion: orig.Strategy.APIVersion,
Name: orig.StrategyName(),
Kind: (*BuildStrategyKind)(orig.Strategy.Kind),
}

// Handle BuildSpec ParamValues
Expand Down Expand Up @@ -213,9 +212,8 @@ func (dest *BuildSpec) ConvertTo(bs *v1alpha1.BuildSpec) error {

// Handle BuildSpec Strategy
bs.Strategy = v1alpha1.Strategy{
Name: dest.StrategyName(),
Kind: (*v1alpha1.BuildStrategyKind)(dest.Strategy.Kind),
APIVersion: dest.Strategy.APIVersion,
Name: dest.StrategyName(),
Kind: (*v1alpha1.BuildStrategyKind)(dest.Strategy.Kind),
}

// Handle BuildSpec Builder, TODO
Expand Down
4 changes: 0 additions & 4 deletions pkg/apis/build/v1beta1/buildstrategy.go
Original file line number Diff line number Diff line change
Expand Up @@ -187,10 +187,6 @@ type Strategy struct {

// BuildStrategyKind indicates the kind of the buildstrategy, namespaced or cluster scoped.
Kind *BuildStrategyKind `json:"kind,omitempty"`

// API version of the referent
// +optional
APIVersion *string `json:"apiVersion,omitempty"`
}

// BuilderStrategy defines the common elements of build strategies
Expand Down
5 changes: 0 additions & 5 deletions pkg/apis/build/v1beta1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading