vectordotdev/vector

Make `vector generate` output documentation

Open

#1687 aperta il 3 feb 2020

Vedi su GitHub
 (3 commenti) (4 reazioni) (0 assegnatari)Rust (2126 fork)batch import
domain: clidomain: configdomain: setupgood first issuetype: enhancement

Metriche repository

Star
 (21.837 star)
Metriche merge PR
 (Merge medio 8g 16h) (110 PR mergiate in 30 g)

Descrizione

Right now vector generate outputs quite minimal configurations.

❯ vector generate "stdin"
data_dir = '/var/lib/vector/'
dns_servers = []
[sources.source0]
max_length = 102400
type = 'stdin'

This issue proposes the output be something like the following:

#                                    __   __  __
#                                    \ \ / / / /
#                                     \ V / / /
#                                      \_/  \/
#
#                                    V E C T O R
#                                   Configuration
#
# ------------------------------------------------------------------------------
# Website: https://vector.dev
# Docs: https://vector.dev/docs/
# ------------------------------------------------------------------------------

# The location of data storage
data_dir = '/var/lib/vector/'
# Custom DNS servers to use (if any)
dns_servers = []

[sources.source0]
# https://vector.dev/docs/reference/sources/stdin/
type = 'stdin'
# The maxiumum bytes size of a message before it is discarded.
max_length = 102400

We may want to opt for a smaller logo, or none at all. We also may want to output commented versions of fields that are using defaults.

Guida contributor