Skip to content

Commit c3605e3

Browse files
committed
Breaking: Normalize keys appcat->helmetica
1 parent 42202c5 commit c3605e3

18 files changed

Lines changed: 44 additions & 44 deletions

pkg/schemagen/schemagen.go

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,10 @@ import (
1414
kubeyaml "sigs.k8s.io/yaml"
1515
)
1616

17-
const CRDKindAnnotation = "crd.bundle.appcat.io/kind"
18-
const CRDListKindAnnotation = "crd.bundle.appcat.io/listKind"
19-
const CRDSingularAnnotation = "crd.bundle.appcat.io/singular"
20-
const CRDPluralAnnotation = "crd.bundle.appcat.io/plural"
17+
const CRDKindAnnotation = "crd.bundle.helmetica.io/kind"
18+
const CRDListKindAnnotation = "crd.bundle.helmetica.io/listKind"
19+
const CRDSingularAnnotation = "crd.bundle.helmetica.io/singular"
20+
const CRDPluralAnnotation = "crd.bundle.helmetica.io/plural"
2121

2222
var crdCategories = []string{"all", "claim", "helmetica"}
2323

@@ -32,7 +32,7 @@ var crdCategories = []string{"all", "claim", "helmetica"}
3232
// - [CRDPluralAnnotation]: The plural name of the CRD. Defaults to lowercase kind + "s".
3333
//
3434
// The generated CRD is namespace-scoped.
35-
// The CRD's group is derived from the chart's version and name, in the format "v<major>.<chart-name>.bundles.appcat.io".
35+
// The CRD's group is derived from the chart's version and name, in the format "v<major>.<chart-name>.helmetica-bundles.io".
3636
//
3737
// The generated CRD has a single version named "bundle", which is served and stored.
3838
//
@@ -129,7 +129,7 @@ func GenerateCRD(chart chartv2.Chart, opts ...GenerateOption) (apiextv1.CustomRe
129129
if err != nil {
130130
return apiextv1.CustomResourceDefinition{}, fmt.Errorf("invalid strict chart version: %s", chart.Metadata.Version)
131131
}
132-
crd.Spec.Group = fmt.Sprintf("v%d.%s.bundles.appcat.io", semver.Major(), chart.Name())
132+
crd.Spec.Group = fmt.Sprintf("v%d.%s.helmetica-bundles.io", semver.Major(), chart.Name())
133133
}
134134

135135
crd.Name = fmt.Sprintf("%s.%s", crd.Spec.Names.Plural, crd.Spec.Group)

pkg/schemagen/testdata/charts/empty.golden.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
apiVersion: apiextensions.k8s.io/v1
22
kind: CustomResourceDefinition
33
metadata:
4-
name: empties.v3.juiceshop.bundles.appcat.io
4+
name: empties.v3.juiceshop.helmetica-bundles.io
55
spec:
6-
group: v3.juiceshop.bundles.appcat.io
6+
group: v3.juiceshop.helmetica-bundles.io
77
names:
88
categories:
99
- all

pkg/schemagen/testdata/charts/empty/Chart.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ version: 3.1.0
2424
appVersion: "1.31.2"
2525

2626
annotations:
27-
crd.bundle.appcat.io/kind: "Empty"
28-
crd.bundle.appcat.io/listKind: "EmptyList"
29-
crd.bundle.appcat.io/singular: "empty"
30-
crd.bundle.appcat.io/plural: "empties"
27+
crd.bundle.helmetica.io/kind: "Empty"
28+
crd.bundle.helmetica.io/listKind: "EmptyList"
29+
crd.bundle.helmetica.io/singular: "empty"
30+
crd.bundle.helmetica.io/plural: "empties"

pkg/schemagen/testdata/charts/emptywithcomment.golden.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
apiVersion: apiextensions.k8s.io/v1
22
kind: CustomResourceDefinition
33
metadata:
4-
name: instances.v3.juiceshop.bundles.appcat.io
4+
name: instances.v3.juiceshop.helmetica-bundles.io
55
spec:
6-
group: v3.juiceshop.bundles.appcat.io
6+
group: v3.juiceshop.helmetica-bundles.io
77
names:
88
categories:
99
- all

pkg/schemagen/testdata/charts/enums.golden.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
apiVersion: apiextensions.k8s.io/v1
22
kind: CustomResourceDefinition
33
metadata:
4-
name: enums.v3.juiceshop.bundles.appcat.io
4+
name: enums.v3.juiceshop.helmetica-bundles.io
55
spec:
6-
group: v3.juiceshop.bundles.appcat.io
6+
group: v3.juiceshop.helmetica-bundles.io
77
names:
88
categories:
99
- all

pkg/schemagen/testdata/charts/enums/Chart.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ version: 3.1.0
2424
appVersion: "1.31.2"
2525

2626
annotations:
27-
crd.bundle.appcat.io/kind: "Enum"
28-
crd.bundle.appcat.io/listKind: "EnumList"
29-
crd.bundle.appcat.io/singular: "enum"
30-
crd.bundle.appcat.io/plural: "enums"
27+
crd.bundle.helmetica.io/kind: "Enum"
28+
crd.bundle.helmetica.io/listKind: "EnumList"
29+
crd.bundle.helmetica.io/singular: "enum"
30+
crd.bundle.helmetica.io/plural: "enums"

pkg/schemagen/testdata/charts/enums/examples/enums-invalid-int.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
apiVersion: v3.juiceshop.bundles.appcat.io/bundle
1+
apiVersion: v3.juiceshop.helmetica-bundles.io/bundle
22
kind: Enum
33
metadata:
44
annotations:

pkg/schemagen/testdata/charts/enums/examples/enums-invalid-string.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
apiVersion: v3.juiceshop.bundles.appcat.io/bundle
1+
apiVersion: v3.juiceshop.helmetica-bundles.io/bundle
22
kind: Enum
33
metadata:
44
annotations:

pkg/schemagen/testdata/charts/enums/examples/enums-invalid-stringarray.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
apiVersion: v3.juiceshop.bundles.appcat.io/bundle
1+
apiVersion: v3.juiceshop.helmetica-bundles.io/bundle
22
kind: Enum
33
metadata:
44
annotations:

pkg/schemagen/testdata/charts/enums/examples/enums-invalid-stringmap.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
apiVersion: v3.juiceshop.bundles.appcat.io/bundle
1+
apiVersion: v3.juiceshop.helmetica-bundles.io/bundle
22
kind: Enum
33
metadata:
44
annotations:

0 commit comments

Comments
 (0)