module

Flock::Cli::Commands::Pack

flock pack [dir] [-o out.flkpack] — bundles a directory of assets (default assets/) into a single .flkpack archive (deflate-compressed, keyed by relative path). Runs Flock::PackWriter from the project's Flock checkout (found via the project config's flock_path), so the CLI needs no compiled Flock itself.

Instance methods

render_script(dir : String, out_path : String) : String

Builds the throwaway Crystal program that crystal eval runs to write the pack. dest/sz/n are ordinary locals here — notably NOT out, which is a reserved Crystal keyword and would fail to compile. User-supplied strings (dir, out_path) are emitted with #inspect so a quote/backslash in them can't break out of the code.

Source
run(args : Array(String)) : Nil
Source