Liking cljdoc? Tell your friends :D

cli-matic.help-gen

## Generate help texts.




raw docstring

arg-list-with-positional-entriesclj/s

(arg-list-with-positional-entries cfg cmd)

Creates the [arguments...]

Creates the `[arguments...]`
sourceraw docstring

generate-a-commandclj/s

(generate-a-command {:keys [command short description]})

Maybe we should use a way to format commands

E.g. (pp/cl-format true "~{ ~vA ~vA ~vA ~}" v)

(clojure.pprint/cl-format true "~3a ~a" "pippo" "pluto")

Maybe we should use a way to format commands

E.g.
(pp/cl-format true "~{ ~vA  ~vA  ~vA ~}" v)


(clojure.pprint/cl-format true "~3a ~a" "pippo" "pluto")
sourceraw docstring

generate-global-command-listclj/s

(generate-global-command-list commands)

Creates a list of commands and descriptions. Commands are of kind ::S/commands

Creates a list of commands and descriptions.
Commands are of kind ::S/commands
sourceraw docstring

generate-global-helpclj/s

(generate-global-help cfg)

This is where we generate global help, so global attributes and subcommands.

This is where we generate global help, so
global attributes and subcommands.
sourceraw docstring

generate-help-possible-mistypesclj/s

(generate-help-possible-mistypes cfg wrong-subcmd)

If we have a wrong subcommand, can we guess what the correct one could have been?

If we have a wrong subcommand, can we guess what the correct
one could have been?


sourceraw docstring

generate-possible-mistypesclj/s

(generate-possible-mistypes wrong-subcmd commands aliases)

We go searching if we have any candidates to be considered mistypes.

We require a miss ratio of MISTYPE-ERR-RATIO and we return them by similarity.

We go searching if we have any candidates
to be considered mistypes.

We require a miss ratio of [[MISTYPE-ERR-RATIO]]
and we return them by similarity.

sourceraw docstring

generate-sectionclj/s

(generate-section title lines)

Generates a section (as a collection of strings, possibly nested, but we'll flatten it out). If a section has no content, we return [].

Generates a section (as a collection of strings,
possibly nested, but we'll flatten it out).
If a section has no content, we return [].
sourceraw docstring

generate-sectionsclj/s

(generate-sections name version usage commands opts-title opts)

Generates all sections. All those positional parameters are not that nice.

Generates all sections.
All those positional parameters are not that nice.
sourceraw docstring

generate-subcmd-helpclj/s

(generate-subcmd-help cfg cmd)

This is where we generate help for a specific subcommand.

This is where we generate help for a specific subcommand.
sourceraw docstring

get-first-rest-description-rowsclj/s

(get-first-rest-description-rows row-or-rows)

get title and description of description rows

get title and description of description rows
sourceraw docstring

get-options-summaryclj/s

(get-options-summary cfg subcmd)

To get the summary of options, we pass options to tools.cli parse-opts and an empty set of arguments. Parsing will fail but we get the :summary. We then split it into a collection of lines.

To get the summary of options, we pass options to
tools.cli parse-opts and an empty set of arguments.
Parsing will fail but we get the :summary.
We then split it into a collection of lines.
sourceraw docstring

MISTYPE-ERR-RATIOclj/s

source

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close