build

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Jul 22, 2026 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	ContentDir      string
	OutputDir       string
	StaticDir       string
	ThemeStaticDir  string // optional: themes/<name>/static (overrides StaticDir for CSS/JS refs)
	LayoutsDir      string
	BaseURL         string
	DefaultLang     string
	SiteTitle       string
	SiteDesc        string
	EditURLBase     string
	Clean           bool
	LiveReload      bool
	SyntaxHighlight bool   // enable Chroma server-side highlighting (slower builds)
	PaginateBy      int    // number of posts per home page (default 10)
	PaginateMode    string // "year" for date-based pagination; default is size-based

	// Build filtering (Hugo-compatible)
	BuildDrafts  bool // --buildDrafts / buildDrafts in config
	BuildFuture  bool // --buildFuture / buildFuture in config
	BuildExpired bool // --buildExpired / buildExpired in config

	// Site-level data exposed to templates
	Params     map[string]any    // [params] in tago.toml → .Site.Params
	Taxonomies map[string]string // custom taxonomies: plural → singular
}

Config holds the build configuration.

type Stats

type Stats struct {
	PagesRebuilt int
	PagesTotal   int
	Duration     time.Duration
}

Stats holds build statistics.

func Build

func Build(cfg *Config) (*Stats, error)

Build runs the full incremental build.

Jump to

Keyboard shortcuts

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