Directories
¶
| Path | Synopsis |
|---|---|
|
Package diag provides diagnostic types and helpers for reporting issues detected during code generation.
|
Package diag provides diagnostic types and helpers for reporting issues detected during code generation. |
|
Package directive parses the //kanna:<key> comment directives that the generators share.
|
Package directive parses the //kanna:<key> comment directives that the generators share. |
|
gen
|
|
|
di
Package di generates dependency-injection constructors from container struct declarations.
|
Package di generates dependency-injection constructors from container struct declarations. |
|
fixture
Package fixture generates plain constructor functions that fill a struct with fake data, one per struct in a source package.
|
Package fixture generates plain constructor functions that fill a struct with fake data, one per struct in a source package. |
|
i18n
Package i18n generates a typed message package from a directory of locale files: one constructor per message, validated across locales, with the translations themselves compiled in.
|
Package i18n generates a typed message package from a directory of locale files: one constructor per message, validated across locales, with the translations themselves compiled in. |
|
i18n/locale
Package locale parses locale files (YAML or TOML) into flat message catalogs.
|
Package locale parses locale files (YAML or TOML) into flat message catalogs. |
|
i18n/template
Package template parses message templates such as "Hello, {name}!".
|
Package template parses message templates such as "Hello, {name}!". |
|
mapper
Package mapper generates mapping functions between two struct types, wiring in the converters a project registers for the field types Go cannot convert on its own.
|
Package mapper generates mapping functions between two struct types, wiring in the converters a project registers for the field types Go cannot convert on its own. |
|
orm
Package orm generates type-safe query code from annotated model structs.
|
Package orm generates type-safe query code from annotated model structs. |
|
Package imports assigns the local names a generated file uses for the packages it imports.
|
Package imports assigns the local names a generated file uses for the packages it imports. |
|
Package ir defines the generator-agnostic model that the scan layer produces and each generator consumes.
|
Package ir defines the generator-agnostic model that the scan layer produces and each generator consumes. |
|
Package output writes what a generator produced, with the guards every generator needs and none should reimplement: never replace a file that is not generated, tell staleness apart from I/O failure, and resolve paths against the directory the tool was invoked in.
|
Package output writes what a generator produced, with the guards every generator needs and none should reimplement: never replace a file that is not generated, tell staleness apart from I/O failure, and resolve paths against the directory the tool was invoked in. |
|
Package packages wraps golang.org/x/tools/go/packages with the loading mode and build-tag handling used by kanna.
|
Package packages wraps golang.org/x/tools/go/packages with the loading mode and build-tag handling used by kanna. |
|
Package pkgtest provides helpers for tests that need a loaded package.
|
Package pkgtest provides helpers for tests that need a loaded package. |
|
Package relation holds the interpretation of orm tags that more than one generator relies on: the tag grammar, the classification of untagged fields, the mechanical name conversion, and the primary-key rule.
|
Package relation holds the interpretation of orm tags that more than one generator relies on: the tag grammar, the classification of untagged fields, the mechanical name conversion, and the primary-key rule. |
|
Package scan extracts a generator-agnostic model of the struct types declared in a set of loaded packages.
|
Package scan extracts a generator-agnostic model of the struct types declared in a set of loaded packages. |
|
Package version reports the version of the running binary.
|
Package version reports the version of the running binary. |
Click to show internal directories.
Click to hide internal directories.