genhelpers

package
v1.28.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 17, 2026 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrLoadPackages = errors.New("failed to load packages")

ErrLoadPackages is returned when Go packages cannot be loaded for comment extraction

Functions

func ChangeToRootDir

func ChangeToRootDir(rootDir string)

ChangeToRootDir changes the working directory to the root of the repository

func HasSchemaChanges added in v0.51.0

func HasSchemaChanges(checksumFile string, directories ...string) (bool, error)

HasSchemaChanges checks if there have been changes to schema or generated files by comparing checksums of the relevant directories

func LoadCommentMap added in v1.28.0

func LoadCommentMap(patterns ...string) (map[string]string, error)

LoadCommentMap parses the packages matched by the given patterns and returns their Go doc comments keyed by "pkgpath.TypeName" for type declarations and "pkgpath.TypeName.FieldName" for exported struct fields; the key format is shared by the jsonschema reflector comment map and the OpenAPI schema customizer so both generators source descriptions the same way

func SetSchemaChecksum added in v0.51.0

func SetSchemaChecksum(checksumFile string, paths ...string) error

SetSchemaChecksum updates the checksum file with the current checksum

func SetupLogging

func SetupLogging()

SetupLogging sets up the logging for the code generation process

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL