1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
//! Command-line interface for the mq markdown processing tool.
//!
//! This crate provides the CLI implementation for mq, a jq-like tool for processing
//! markdown files. It handles command-line argument parsing, input/output processing,
//! and integration with the mq language engine.
//!
//! # Features
//!
//! - Process markdown, MDX, HTML, and plain text inputs
//! - Support for file and stdin input
//! - Multiple output formats
//! - Optional debugger integration (with `debugger` feature)
//! - Configuration file support
//! - Interactive REPL mode
//!
//! # Usage
//!
//! The CLI is typically used through the `mq` binary, but can be embedded in other applications:
//!
//! ```rust,no_run
//! use mq_run::Cli;
//! use clap::Parser;
//!
//! let cli = Cli::parse();
//! cli.run().expect("CLI execution failed");
//! ```
//!
//! # Command-line Examples
//!
//! Process markdown from a file:
//! ```bash
//! mq '.h' input.md
//! ```
//!
//! Filter headings from stdin:
//! ```bash
//! echo "# Title\nContent" | mq '.h | select(level == 1)'
//! ```
//!
//! Use the REPL:
//! ```bash
//! mq --repl
//! ```
pub
pub
pub use Cli;