Skip to content

Commit

Permalink
removing Strategy.APIversion
Browse files Browse the repository at this point in the history
  • Loading branch information
apoorvajagtap committed Oct 9, 2023
1 parent 1660379 commit d0a401d
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 15 deletions.
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.

0 comments on commit d0a401d

Please sign in to comment.