Use the mdbook-man crate to generate man pages from your Rust CLI's clap or argh configuration. Add the dependency to your Cargo.toml, then run the build command to output the man page file.
[dependencies]
mdbook-man = "0.1"
cargo run --bin your-cli -- --man-page
Alternatively, if using clap, enable the derive feature and run:
cargo install mdbook-man
cargo run --bin your-cli -- --help | mdbook-man > your-cli.1