Documentation
¶
Overview ¶
Command quark is the Quark ORM CLI: model scaffolding, migrations, seeders, multi-tenancy helpers, and code generation.
Install it with:
go install github.com/jcsvwinston/quark/cmd/quark@latest
and drive code generation from a model package with:
//go:generate quark gen ./...
Directories
¶
| Path | Synopsis |
|---|---|
|
internal
|
|
|
codegen
Package codegen implements `quark gen`: it parses a user's package with go/packages + go/types (not reflection, so the tool can be `go install`ed and driven from //go:generate) and emits, per package, a quark_gen.go that registers typed implementations with the runtime registry in package quark.
|
Package codegen implements `quark gen`: it parses a user's package with go/packages + go/types (not reflection, so the tool can be `go install`ed and driven from //go:generate) and emits, per package, a quark_gen.go that registers typed implementations with the runtime registry in package quark. |
|
codegen/sample
Package sample holds a representative model used by the codegen tests: the conformance test loads it via go/packages (AST) and via reflection, and the golden test regenerates its quark_gen.go and compares.
|
Package sample holds a representative model used by the codegen tests: the conformance test loads it via go/packages (AST) and via reflection, and the golden test regenerates its quark_gen.go and compares. |
Click to show internal directories.
Click to hide internal directories.