Skip to content

Commit 2195346

Browse files
committed
Add generation of applyconfigurations (again)
Signed-off-by: Erik Godding Boye <egboye@gmail.com>
1 parent 2b63756 commit 2195346

File tree

15 files changed

+126
-216
lines changed

15 files changed

+126
-216
lines changed

make/02_mod.mk

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,3 +71,19 @@ release-debian-bookworm-trust-package: | $(NEEDS_CRANE)
7171
@echo "RELEASE_OCI_PACKAGE_DEBIAN_BOOKWORM_TAG=$(oci_package_debian_bookworm_image_tag)" >> "$(GITHUB_OUTPUT)"
7272

7373
@echo "Release complete!"
74+
75+
.PHONY: generate-applyconfigurations
76+
## Generate applyconfigurations to support typesafe SSA.
77+
## @category Generate/ Verify
78+
generate-applyconfigurations: | $(NEEDS_APPLYCONFIGURATION-GEN)
79+
$(eval apis := $(shell find pkg/apis -mindepth 2 -type d | sed "s|^|$(repo_name)/|" | paste -sd ","))
80+
81+
rm -rf pkg/applyconfigurations
82+
83+
$(APPLYCONFIGURATION-GEN) \
84+
--go-header-file $(go_header_file) \
85+
--output-dir "pkg/applyconfigurations" \
86+
--output-pkg "$(repo_name)/pkg/applyconfigurations" \
87+
$(apis)
88+
89+
shared_generate_targets += generate-applyconfigurations

pkg/applyconfigurations/internal/internal.go

Lines changed: 3 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pkg/applyconfigurations/trust/v1alpha1/additionalformats.go

Lines changed: 3 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pkg/applyconfigurations/trust/v1alpha1/bundle.go

Lines changed: 28 additions & 23 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pkg/applyconfigurations/trust/v1alpha1/bundlecondition.go

Lines changed: 0 additions & 88 deletions
This file was deleted.

pkg/applyconfigurations/trust/v1alpha1/bundlesource.go

Lines changed: 3 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)