• v0.1.1 85526a92ab

    v0.1.1 Stable

    panda released this 2025-12-04 06:30:04 +08:00 | 1 commits to main since this release

    LitBlock v0.1.1

    Released 2025-04-12

    This provides a tool for authoring literate, token-addressable code-blocks inside Markdown for POSIX compatible systems.

    Features

    Single-binary CLI (bin/litblock)

    • Written in portable sh, no external runtime required.
    • Treats any fenced code-block that starts at column 0 and ends with a guillemet label («label») as an addressable “litblock”.

    Two core operations

    1. litblock "<pattern>" [file] → extract the matching block.
    2. litblock --list [file] → enumerate all labels.

    Flexible I/O paths

    • Works on a file, on stdin, or via the environment (LITBLOCK_SRC).
    • Output can be redirected with LITBLOCK_DEST and suppressed/forced with LITBLOCK_STDOUT.

    Deterministic extraction

    • Uses a single sed range expression, guaranteeing contiguous multi-block matches when the same label is reused.
    • Result is pipable straight into interpreters, compilers, renderers, etc.

    A install script for local installs (pending a PKGBUILD)

    • ./install.sh [install|uninstall] drops the binary under $HOME/.local/bin (overridable with PREFIX).
    Downloads