kubernetes-client / gen

Common generator scripts for all client libraries
Apache License 2.0
148 stars 148 forks source link

Adding scripts for java CRD model generation #162

Closed yue9944882 closed 4 years ago

yue9944882 commented 4 years ago

the usage of the scripts will be printed on -h flag:

Usage: generate a java project using input openapi spec from stdin
 -c: project version of the generated java project.
 -n: the prefix of the target CRD's api group to generate.
 -p: the base package name of the generated java project. 
 -o: output directory of the generated java project. 
 -l: keep the n last segments for the generated class name. 

example:

bash java-crd.sh -l 2 -n io.example -c 1.0.0 -p io.example -o /tmp/java < /tmp/swagger

/cc @brendandburns @aespinosa

k8s-ci-robot commented 4 years ago

@yue9944882: GitHub didn't allow me to request PR reviews from the following users: aespinosa.

Note that only kubernetes-client members and repo collaborators can review this PR, and authors cannot review their own PRs.

In response to [this](https://github.com/kubernetes-client/gen/pull/162): >the usage of the scripts will be printed on `-h` flag: > >``` >Usage: generate a java project using input openapi spec from stdin > -c: project version of the generated java project. > -n: the prefix of the target CRD's api group to generate. > -p: the base package name of the generated java project. > -o: output directory of the generated java project. > -l: keep the n last segments for the generated class name. >``` > >example: > >```sh >bash java-crd.sh -l 2 -n io.example -c 1.0.0 -p io.example -o /tmp/java < /tmp/swagger >``` > >/cc @brendandburns @aespinosa Instructions for interacting with me using PR comments are available [here](https://git.k8s.io/community/contributors/guide/pull-requests.md). If you have questions or suggestions related to my behavior, please file an issue against the [kubernetes/test-infra](https://github.com/kubernetes/test-infra/issues/new?title=Prow%20issue:) repository.
brendandburns commented 4 years ago

/lgtm /approve

k8s-ci-robot commented 4 years ago

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: brendandburns, yue9944882

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files: - ~~[OWNERS](https://github.com/kubernetes-client/gen/blob/master/OWNERS)~~ [brendandburns] Approvers can indicate their approval by writing `/approve` in a comment Approvers can cancel approval by writing `/approve cancel` in a comment