Documentation
¶
Overview ¶
Package projectfile discovers and validates the structural ridu.toml file owned by a generated application.
Index ¶
Constants ¶
const CurrentVersion = 1
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DatabaseAdapter ¶
type DatabaseAdapter string
DatabaseAdapter is the closed set of official stores selectable by an ordinary project. Connection details remain runtime-owned and are not serialized into ridu.toml.
const ( DatabasePostgres DatabaseAdapter = "postgres" DatabaseSQLite DatabaseAdapter = "sqlite" DatabaseMongoDB DatabaseAdapter = "mongodb" )
type File ¶
type File struct {
Path string
Root string
Version int
Database DatabaseAdapter
PackageManager PackageManager
Entry string
Admin string
Client string
Schema string
OpenAPI string
Migrations string
Assets string
Plugins string
PluginGo string
GeneratedArtifacts []GeneratedArtifact
}
File is a validated project definition rooted at the directory containing ridu.toml. Structural paths are always relative and cannot escape Root.
func (File) FrontendPackageManager ¶
func (project File) FrontendPackageManager() PackageManager
FrontendPackageManager returns the configured manager. Bun is the fallback only for projects created before package_manager was added to version 1.
type GeneratedArtifact ¶
GeneratedArtifact maps one compiled plugin artifact to a project-relative destination. Plugin and Name form the protocol identity.
type PackageManager ¶
type PackageManager string
PackageManager is the frontend dependency manager selected by a project. Existing version-1 project files that omit the key retain Bun for backwards compatibility; newly scaffolded projects always write the selection.
const ( PackageManagerBun PackageManager = "bun" PackageManagerNPM PackageManager = "npm" PackageManagerPNPM PackageManager = "pnpm" PackageManagerYarn PackageManager = "yarn" )
func (PackageManager) Valid ¶
func (manager PackageManager) Valid() bool
Valid reports whether manager is one of the supported frontend package managers.