Skip to content

Commit

Permalink
Merge pull request #123735 from thockin/master
Browse files Browse the repository at this point in the history
Don't embed plural exceptions in tools
  • Loading branch information
k8s-ci-robot committed Mar 7, 2024
2 parents 2ec63e0 + df7f5fc commit a31a465
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
4 changes: 4 additions & 0 deletions hack/update-codegen.sh
Expand Up @@ -37,6 +37,7 @@ API_KNOWN_VIOLATIONS_DIR="${API_KNOWN_VIOLATIONS_DIR:-"${KUBE_ROOT}/api/api-rule
OUT_DIR="_output"
BOILERPLATE_FILENAME="hack/boilerplate/boilerplate.generatego.txt"
APPLYCONFIG_PKG="k8s.io/client-go/applyconfigurations"
PLURAL_EXCEPTIONS="Endpoints:Endpoints"

# Any time we call sort, we want it in the same locale.
export LC_ALL="C"
Expand Down Expand Up @@ -642,6 +643,7 @@ function codegen::clients() {
--output-pkg="k8s.io/client-go" \
--clientset-name="kubernetes" \
--input-base="k8s.io/api" \
--plural-exceptions "${PLURAL_EXCEPTIONS}" \
--apply-configuration-package "${APPLYCONFIG_PKG}" \
$(printf -- " --input %s" "${gv_dirs[@]}") \
"$@"
Expand Down Expand Up @@ -682,6 +684,7 @@ function codegen::listers() {
--go-header-file "${BOILERPLATE_FILENAME}" \
--output-dir "${KUBE_ROOT}/staging/src/k8s.io/client-go/listers" \
--output-pkg "k8s.io/client-go/listers" \
--plural-exceptions "${PLURAL_EXCEPTIONS}" \
"${ext_apis[@]}" \
"$@"

Expand Down Expand Up @@ -724,6 +727,7 @@ function codegen::informers() {
--single-directory \
--versioned-clientset-package "k8s.io/client-go/kubernetes" \
--listers-package "k8s.io/client-go/listers" \
--plural-exceptions "${PLURAL_EXCEPTIONS}" \
"${ext_apis[@]}" \
"$@"

Expand Down
Expand Up @@ -69,7 +69,6 @@ func New() *Args {
ClientsetAPIPath: "/apis",
ClientsetOnly: false,
FakeClient: true,
PluralExceptions: []string{"Endpoints:Endpoints"},
ApplyConfigurationPackage: "",
}
}
Expand Down
Expand Up @@ -40,8 +40,7 @@ type Args struct {
// New returns default arguments for the generator.
func New() *Args {
return &Args{
SingleDirectory: false,
PluralExceptions: []string{"Endpoints:Endpoints"},
SingleDirectory: false,
}
}

Expand Down
Expand Up @@ -35,9 +35,7 @@ type Args struct {

// New returns default arguments for the generator.
func New() *Args {
return &Args{
PluralExceptions: []string{"Endpoints:Endpoints"},
}
return &Args{}
}

// AddFlags add the generator flags to the flag set.
Expand Down

0 comments on commit a31a465

Please sign in to comment.