flags

Named on/off feature flags read from configuration, failing closed: unknown names are off, bad values are errors.

Built and tested in the harness, and not in the public repository yet. The install line and the source link appear here when it is.

What it is

flags.

Declares named on/off feature flags and resolves them from the venture’s configuration. A flag named payouts-rapyd is read from FLAG_PAYOUTS_RAPYD. The values on, true, 1 and yes switch a flag on, and off, false, 0 and no switch it off, in any case. An absent or blank value takes the declared default. Any other value is an error that names the key, so a typo never switches a flag silently. A name that was not declared reads as off. Flags are a switch for availability, not for security: a venture uses them to remove a feature, never to skip a check that protects the features that remain.

From the crate’s own README.

History

Changelog.

Not released yet. Its changelog starts with its first release.

One of 95 crates in the harness, all of them MIT.