module Bakelite::DSL

Direct including types

Defined in:

bakelite/dsl.cr

Macro Summary

Macro Detail

macro bake(path, as_path = nil, volume = :root, transform = nil) #

Direct compile-time inlined bake of a single file. Inlines static bytes into the binary for zero-copy, instantaneous string reads.


macro bake_folder(dir, prefix = "", volume = :root, transform = nil, exclude = [] of String) #

Embeds all files in a folder directly as inlined bakes using single-pass batch processing.


macro bake_manifest(manifest_path, base_dir = ".") #

Declarative multi-volume manifest baking. Reads a YAML manifest defining volumes, mount points, chunk sizes, compression, auto thresholds, file inclusion globs, and negative/exclusion patterns. Processes all volumes and assets in a single ultra-fast pass (<200ms).


macro define_volume(name, mount = "", priority = 0, chunk_size = 65536, compress = :deflate, &block) #

Macro alias for volume definition


macro embed_folder(dir, prefix = "", volume = :root, auto = true, threshold = 16384, chunk_size = 65536, compress = :deflate, exclude = [] of String) #

Smart auto-embedding using single-pass batch processing: inlines small text files, chunks large files.


macro store(path, as_path = nil, volume = :root, chunk_size = 65536, compress = :deflate, transform = nil) #

Chunked, compressed, and stream-backed store of a file. Reads through Bakelite::FileIO in O(chunk_size) RAM.


macro store_folder(dir, prefix = "", volume = :root, chunk_size = 65536, compress = :deflate, transform = nil, exclude = [] of String) #

Stores all files in a folder as chunked, compressed streaming assets using single-pass batch processing.


macro volume(name, mount = "", priority = 0, chunk_size = 65536, compress = :deflate, &block) #

Creates and mounts a custom volume with specific mount point, chunk size, and priority.