Skip to content
Myr

clarity to Feature Switches

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Estevan Pequeno · committed by Estevan Pequeno · parent deae54c · Browse files · 1 file+3 added−3 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+3 added−3 removed

  • other:+3 added−3 removed

1 file+3 added−3 removed

modified:docs/options.rst+3 added-3 removed
3 unmodified lines
4.. currentmodule:: click56Adding options to commands can be accomplished by the :func:`option`7decorator. Since options can come in various different versions there8have a ton of parameters to configure their behavior.8are a ton of parameters to configure their behavior.910Basic Value Options11-------------------12
88 unmodified lines
101----------------102103In addition to boolean flag there are also feature switches. These are104implemented by setting multiple options to the same parameter name and by105defining a flag value. To select a default the default flag can be set to106`True` on the one that should be the default.105defining a flag value. To set a default flag assign a value of `True` to106the flag that should be the default.107108Example::109110 import os
221 unmodified lines