gleamcms/builder/generator

Types

pub type BuildReport {
  BuildReport(
    theme_name: String,
    pages_written: Int,
    output_dir: String,
    errors: List(String),
  )
}

Constructors

  • BuildReport(
      theme_name: String,
      pages_written: Int,
      output_dir: String,
      errors: List(String),
    )

Values

pub fn build(
  db: process.Subject(transactor.Message),
  theme_name: String,
  cfg: config.Config,
) -> BuildReport

Build one themed site → gleamcms_output//

Thin wrapper over do_build (the single renderer implementation) that supplies every published post. Previously build/2 and do_build/3 were two near-identical copies of the same write logic.

pub fn build_all(
  db: process.Subject(transactor.Message),
  cfg: config.Config,
) -> List(BuildReport)

Build ALL 50 themes → one report per theme.

pub fn build_showcase(
  db: process.Subject(transactor.Message),
  cfg: config.Config,
) -> List(BuildReport)

Specialized build: 50 sites, each with exactly ONE unique post.

pub fn list_generated(cfg: config.Config) -> List(String)

List theme slugs that have already been generated on disk.

pub fn seed_showcase_posts(
  db: process.Subject(transactor.Message),
) -> Result(Nil, List(String))
Search Document