Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Generate manpages and include them in prebuilt releases #88

Closed
bradlarsen opened this issue Oct 16, 2023 · 5 comments
Closed

Generate manpages and include them in prebuilt releases #88

bradlarsen opened this issue Oct 16, 2023 · 5 comments
Labels
enhancement New feature or request help wanted Extra attention is needed packaging Related to packaging and distribution

Comments

@bradlarsen
Copy link
Collaborator

The prebuilt releases could include man pages generated from the CLI documentation.

See clap_mangen. This would possibly need to be called from the build.rs script. Then, in the scripts/create_release.zsh script, we would want to copy those generated man pages into somewhere like release/share/man/1/.

@bradlarsen bradlarsen added enhancement New feature or request help wanted Extra attention is needed packaging Related to packaging and distribution labels Oct 16, 2023
@munntjlx
Copy link
Contributor

I can help write manpages in Markdown format if appropriate summaries of things are done? Which md2man utility do we want to use?

@munntjlx
Copy link
Contributor

Also which 'template' format for MD to make happy MAN pages, there are tons of them, I suspect you want a rust specific one?

@munntjlx
Copy link
Contributor

munntjlx commented Oct 24, 2023

Here are a few of the ones I found, the PANDOC one seems compelling:
https://gabmus.org/posts/man_pages_with_markdown_and_pandoc/

There is also 'ronn'

And a native RUST library:

https://github.com/elebihan/manpages (which seems to require pandoc)

And THIS:

https://gitlab.com/kornelski/mandown

And finally, this: (seems most comprehensive)

https://rust-lang.github.io/mdBook/

@bradlarsen
Copy link
Collaborator Author

Also which 'template' format for MD to make happy MAN pages, there are tons of them, I suspect you want a rust specific one?

Oh, I don't have anything particular in mind. Probably the most expedient thing to do would simply use that clap_mangen Rust library to auto-generate manpages from the already-existent command-line help. Writing higher-level documentation is a bigger task for sure.

@bradlarsen
Copy link
Collaborator Author

Note, the existing command-line documentation is pulled automatically from Rust doc comments in https://github.com/praetorian-inc/noseyparker/blob/main/crates/noseyparker-cli/src/args.rs, via the clap library for CLI parsing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed packaging Related to packaging and distribution
Projects
None yet
Development

No branches or pull requests

2 participants