cli module #84

Closed
opened 2024-06-27 17:12:28 +02:00 by cscherrNT · 2 comments
Collaborator

The idea here is just to bundle a bunch of useful CLI stuff together, and some stuff to make it easier to use. There are probably people that do it better than I do (and put in a lot more work), so prefer to use a dep if possible.

Reexports

  • indicatiff
  • console
  • dialogue
  • comfy_table
  • clap

Evaluate deps

Extras

  • add a borderprinter function that prints text as wide as possible with comfy_tables and accepts a color
  • Initializing of a logger (optional)
  • easy configuration of loglevel/verbosity with cli options
  • repl helpers #86
  • would it be possible to use clap commands to define a repl?
  • make sure that tracing has no incompatabilites
  • automatic/easy generation of man pages with clap_mangen

Structural changes to other components

  • add a cli feature and module
  • move printing to cli

examples

  • repl example project

tests

  • find out how to test blockfmt
  • somehow test VerbosityLevel flags to levels
The idea here is just to bundle a bunch of useful CLI stuff together, and some stuff to make it easier to use. There are probably people that do it better than I do (and put in a lot more work), so prefer to use a dep if possible. **Reexports** - [x] indicatiff - [x] console - [x] dialogue - [x] comfy_table - [x] clap **Evaluate deps** - [x] [easy_repl](https://docs.rs/easy-repl/latest/easy_repl/) **Extras** - [x] add a `borderprinter` function that prints text as wide as possible with comfy_tables and accepts a color - ~~[ ] Initializing of a logger (optional)~~ - [x] easy configuration of loglevel/verbosity with cli options - [x] repl helpers #86 - [x] would it be possible to use clap commands to define a repl? - ~~[ ] make sure that tracing has no incompatabilites~~ - ~~[ ] automatic/easy generation of man pages with clap_mangen~~ **Structural changes to other components** - [x] add a cli feature and module - [x] move printing to `cli` **examples** - [x] repl example project **tests** - [x] find out how to test blockfmt - [x] somehow test VerbosityLevel flags to levels
cscherrNT added the
Kind/Feature
Reviewed
Confirmed
Priority
High
labels 2024-06-27 17:12:28 +02:00
cscherrNT added this to the (deleted) project 2024-06-27 17:12:28 +02:00
PlexSheep changed title from feature: cli module to FEAT: cli module 2024-06-27 21:05:08 +02:00
Owner

easy_repl is a good codebase, but it does not quite do what I want, so I'd rather try to implement a repl system myself. I will try to reuse what I think works good there. (It's MIT licensed)

easy_repl is a good codebase, but it does not quite do what I want, so I'd rather try to implement a repl system myself. I will try to reuse what I think works good there. (It's MIT licensed)
PlexSheep changed title from FEAT: cli module to cli module 2024-06-28 00:49:01 +02:00
Owner

clap_mangen seems to only work with the clap builder API, which I don't like

tests are done with the doc tests and examples

clap_mangen seems to only work with the clap builder API, which I don't like tests are done with the doc tests and examples
This repo is archived. You cannot comment on issues.
No Milestone
No project
No Assignees
2 Participants
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: PlexSheep/pt#84
No description provided.