You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We do not currently supply man pages for Volta. However, it would be relatively straightforward to implement using the clap_mangen crate, since we already use clap for our CLI parser. If someone wants to implement it, it should be a relatively easy first issue.
Add a new man_pages module as a sibling to completions and the others.
Define a new clap argument with a pub(crate) struct ManPages.
Implement Volta’s Command trait for ManPages, including logging events the same basic way Completionts does (so you will also need to add a new ActivityKind etc.) for it.
Use the Man struct from clap_mangen to generate the man pages from the command (crate::cli::Volta::command()).
Emit the generated roff to the appropriate location. (You will have to see where that is on a per-OS basis!) One note that adds a small bit of complexity here: there is no “default” place to install it on Windows, as far as I know, but we should presumably still support it for someone who wants to read them there.
Hi I was working on it but I am not sure about , last two parts can you guide me a more, I am a student and new to open source , I have some knowledge of rust and want to contribute. A little help would be appreciated .
We do not currently supply man pages for Volta. However, it would be relatively straightforward to implement using the
clap_mangen
crate, since we already use clap for our CLI parser. If someone wants to implement it, it should be a relatively easy first issue.For a rough idea of how to implement it, you would want to do roughly what we do in
src/command/completions.rs
:clap_mangen
as a dependency for that crate.man_pages
module as a sibling tocompletions
and the others.pub(crate) struct ManPages
.Command
trait forManPages
, including logging events the same basic wayCompletionts
does (so you will also need to add a newActivityKind
etc.) for it.Man
struct fromclap_mangen
to generate the man pages from the command (crate::cli::Volta::command()
).(Originally posted as a comment by @chriskrycho in #1708 (comment))
The text was updated successfully, but these errors were encountered: