diff options
| author | Tim Hockin <thockin@google.com> | 2016-06-06 22:46:24 -0700 |
|---|---|---|
| committer | Tim Hockin <thockin@google.com> | 2016-07-07 16:49:46 -0700 |
| commit | 4a69f7cd28fa45c3f34dfa1a2e89ca09bdea5294 (patch) | |
| tree | 8c91311afa8f9ce893606c5ef9d9f65b183bb944 /adding-an-APIGroup.md | |
| parent | 0bc86fd69bd94f5a8437b5a2b36578ad83fe49c9 (diff) | |
Use file tags to generate deep-copies
This drives most of the logic of deep-copy generation from tags like:
// +deepcopy-gen=package
..rather than hardcoded lists of packages. This will make it possible to
subsequently generate code ONLY for packages that need it *right now*, rather
than all of them always.
Also remove pkgs that really do not need deep-copies (no symbols used
anywhere).
Diffstat (limited to 'adding-an-APIGroup.md')
| -rw-r--r-- | adding-an-APIGroup.md | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/adding-an-APIGroup.md b/adding-an-APIGroup.md index c2197761..6026cc2e 100644 --- a/adding-an-APIGroup.md +++ b/adding-an-APIGroup.md @@ -75,12 +75,14 @@ cmd/libs/go2idl/ tool. 1. Generate conversions and deep-copies: 1. Add your "group/" or "group/version" into - cmd/libs/go2idl/{conversion-gen, deep-copy-gen}/main.go; + cmd/libs/go2idl/conversion-gen/main.go; 2. Make sure your pkg/apis/`<group>`/`<version>` directory has a doc.go file + with the comment `// +k8s:deepcopy-gen=register`, to catch the attention + of our generation tools. + 3. Make sure your pkg/apis/`<group>`/`<version>` directory has a doc.go file with the comment `// +genconversion=true`, to catch the attention of our gen-conversion script. - 3. Run hack/update-all.sh. - + 4. Run hack/update-all.sh. 2. Generate files for Ugorji codec: |
