help_crafter

Crates.iohelp_crafter
lib.rshelp_crafter
version0.3.1
sourcesrc
created_at2023-05-31 09:25:49.244195
updated_at2023-06-03 05:51:52.135593
descriptionSimple help message generator without hussle
homepagehttps://github.com/drp4rad0x/help_crafter
repositoryhttps://github.com/drp4rad0x/help_crafter
max_upload_size
id878637
size14,725
(drp4rad0x)

documentation

https://docs.rs/help_crafter/latest/help_crafter/

README

Help Crafter

This crate provides simple method for generating help messages for your CLI application.

Quick Start

  1. command() for chaining commands to build help message
  2. build() for generate help message

Example

use help_crafter::enums::{DASHED, Parameter};
use help_crafter::HelpMessageBuilder;

   let help = HelpMessageBuilder::default()
   .command("i", "index", Parameter::NO, "index", DASHED::YES)
   .command(
       "k",
       "kill",
       Parameter::REQUIRED("sessions_id"),
       "the big brown fox jumps over the lazy dog the big brown fox",
       DASHED::YES,
   )
   .command(
       "",
       "rub",
       Parameter::OPTIONAL("something"),
       "rub something",
       DASHED::NO,
   )
   .command(
       "t",
       "",
       Parameter::REQUIRED("something"),
       "t something",
       DASHED::YES,
   )
   .command(
       "o",
       "",
       Parameter::OPTIONAL("something"),
       "o something",
       DASHED::NO,
   )
   .build();
Commit count: 16

cargo fmt