Skip to content

Commit b0421f3

Browse files
Merge pull request #735 from bradmwilliams/releasepayload-crd-generation-fix
Adding the ability to (re-)create the ReleasePayload CRD
2 parents 42530bf + 3e0e848 commit b0421f3

1 file changed

Lines changed: 11 additions & 0 deletions

File tree

Makefile

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,17 @@ verify-codegen-script:
3030

3131
# Ensure codegen is run before generating the CRD, so updates to Godoc are included.
3232
update-crd: update-codegen-script update-codegen-crds
33+
.PHONY: update-crd
34+
35+
# Create CRD from scratch using the 'crd' generator instead of 'schemapatch'
36+
# This target can regenerate the CRD even if it doesn't exist, unlike update-crd
37+
# which uses 'schemapatch' and only patches existing CRDs.
38+
create-crd: update-codegen-script ensure-controller-gen
39+
'$(CONTROLLER_GEN)' \
40+
crd \
41+
paths="./pkg/apis/release/v1alpha1" \
42+
'output:crd:dir=./artifacts'
43+
.PHONY: create-crd
3344

3445
sonar-reports:
3546
go test ./... -coverprofile=coverage.out -covermode=count -json > report.json

0 commit comments

Comments
 (0)