Ecosyste.ms: Packages

An open API service providing package, version and dependency metadata of many open source software ecosystems and registries.

Top 8.6% on proxy.golang.org

proxy.golang.org : github.com/sergeymakinen/go-cmdbuilder/v2

Package cmdbuilder implements a converter from structs defining command-line arguments and their values back to a command-line. The cmdbuilder package aims to be compatible with the flags package (see https://github.com/jessevdk/go-flags), so it also uses structs, the reflection and struct field tags to specify command-line arguments. For example: This specifies the 'Verbose' boolean option with a short name '-v' and a long name '--verbose', the 'AuthorInfo' map option with a short name '-a', and the 'Name' string option with a long name '--name' and an optional value. If the struct is initialized as the following: Then the CommandLine function will produce the following string: Any type that implements the Marshaler interface may fully customize its value output. The terms "argument" and "option" are used here as specified by Program Argument Syntax Conventions of The GNU C Library Reference Manual (see https://www.gnu.org/software/libc/manual/html_node/Argument-Syntax.html): The following is a list of supported struct field tags (which is a subset of supported tags by the flags package): At least one is required: Optional:

Registry - Source - Documentation - JSON
purl: pkg:golang/github.com/sergeymakinen/go-cmdbuilder/v2
Keywords: arguments-converter, cmd, cmdline, command-line, commandline, flag, flags, go, golang
License: BSD-3-Clause
Latest release: over 3 years ago
First release: over 3 years ago
Namespace: github.com/sergeymakinen/go-cmdbuilder
Stars: 1 on GitHub
Forks: 0 on GitHub
See more repository details: repos.ecosyste.ms
Last synced: 29 days ago

    Loading...
    Readme
    Loading...