Sign in

    md-outline

    Markdown outline and section reader CLI for agent workflows

    markdown
    outline
    toc
    cli
    wasm
    Download zip
    Version
    0.2.1
    License
    Apache-2.0
    Last updated
    4 months ago
    Downloads
    75

    #peter-jerry-ye/md-outline

    CliCommand

    pub(all) enum CliCommand {
    Toc(String)
    Section(String, String)
    ParseOutput(ToolOutput)
    } derive(Eq, ToJson,
    Debug
    )

    Heading

    pub(all) struct Heading {
    level : Int
    title : String
    line : Int
    end_line : Int
    path : Array[String]
    } derive(Eq, ToJson,
    Debug
    )

    Section

    pub(all) struct Section {
    heading : Heading
    content : String
    } derive(Eq, ToJson,
    Debug
    )

    ToolOutput

    pub(all) enum ToolOutput {
    Stdout(String)
    Stderr(String)
    } derive(Eq, ToJson,
    Debug
    )

    get_section

    fn get_section(markdown : String, query : String) -> Section?

    parse_command

    fn parse_command(argv : Array[String]) -> CliCommand

    read_toc

    fn read_toc(markdown : String) -> Array[Heading]

    render_section

    fn render_section(markdown : String, file_path : String, query : String) -> String?

    render_toc

    fn render_toc(markdown : String, file_path? : String) -> String

    section_tool

    fn section_tool(file_path : String, markdown : String, query : String) -> ToolOutput

    toc_tool

    fn toc_tool(file_path : String, markdown : String) -> ToolOutput

    Powered by MoonBit

    Site sourceReport issuePackagesBuild queueSkillsStatistics

    © 2026 mooncakes.io