github.com/ActiveState/cli@v0.0.0-20240508170324-6801f60cd051/cmd/state-svc/gqlgen.yml (about) 1 # Where are all the schema files located? globs are supported eg src/**/*.graphqls 2 schema: 3 - schema/*.graphqls 4 5 # Where should the generated server code go? 6 # This is targeting an exclusive package because 7 # gqlgen READS the packages before it writes to them 8 # Making iterative changes difficult if you mix 9 # generated with curated files. 10 exec: 11 filename: internal/server/generated/generated.go 12 package: genserver 13 14 # Uncomment to enable federation 15 # federation: 16 # filename: graph/generated/federation.go 17 # package: generated 18 19 # Where should any generated models go? 20 model: 21 filename: ../../internal/graph/generated.go 22 package: graph 23 24 # Generating the resolver is only really useful if you have a LOT of boilerplate to generate, otherwise it tends 25 # to just break when you make schema changes and it's much easier to just implement the interface as needed 26 #resolver: 27 # layout: follow-schema 28 # dir: internal/resolver/generated 29 # package: genresolver 30 31 # Optional: turn on use `gqlgen:"fieldName"` tags in your models 32 # struct_tag: json 33 34 # Optional: turn on to use []Thing instead of []*Thing 35 # omit_slice_element_pointers: false 36 37 # Optional: set to speed up generation time by not performing a final validation pass. 38 # skip_validation: true 39 40 # gqlgen will search for any type names in the schema in these go packages 41 # if they match it will use them, otherwise it will generate them. 42 autobind: 43 - "github.com/ActiveState/cli/internal/graph" 44 45 # This section declares type mapping between the GraphQL and go type systems 46 # 47 # The first line in each type will be used as defaults for resolver arguments and 48 # modelgen, the others will be allowed when binding to fields. Configure them to 49 # your liking 50 models: 51 ID: 52 model: 53 - github.com/99designs/gqlgen/graphql.ID 54 - github.com/99designs/gqlgen/graphql.Int 55 - github.com/99designs/gqlgen/graphql.Int64 56 - github.com/99designs/gqlgen/graphql.Int32 57 Int: 58 model: 59 - github.com/99designs/gqlgen/graphql.Int 60 - github.com/99designs/gqlgen/graphql.Int64 61 - github.com/99designs/gqlgen/graphql.Int32