-
Notifications
You must be signed in to change notification settings - Fork 187
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
protoc-gen-ent: support
entgql.Annotation
Added support for `entgql.Annotation` to the `protoc-gen-ent` plugin. It should now be possible to generate an Ent schema and its GraphQL configuration from a Protocol Buffer file. The `opts.proto` was updated adding `GQL` child MessageTypes to the existing MessageTypes (`Schema`, `Field`, `Edge`). The associated generated code (`opts.pb.go`) was regenerated using `protoc-gen-go`. The AST generation code in `schemaast/annotation.go` was updated to know about the `entgql` annotations. The new method attempts to generate code similar to that in the documentation. The main package was updated to map the configuration settings in the updated `opts.proto` to the corresponding annotations for the schema, fields, and edges.
- Loading branch information
1 parent
bbd64e9
commit d82c1b6
Showing
4 changed files
with
698 additions
and
85 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.