[][src]Module spirit::utils

Various utilities.

All the little things that are useful through the spirit's or user's code, and don't really fit anywhere else.

Structs

Hidden

A wrapper to hide a configuration field from logs.

MissingEquals

An error returned when the user passes a key-value option without the equal sign.

Enums

ErrorLogFormat

How to format errors in logs.

Functions

absolute_from_os_str

Tries to read an absolute path from the given OS string.

deserialize_opt_duration

Deserialize an Option<Duration> using the [humantime] crate.

key_val

A helper for deserializing map-like command line arguments.

log_error

Log one error on given log level.

log_errors

A wrapper around a fallible function, logging any returned errors.

serialize_duration

Serialize a duration.

serialize_opt_duration

Serialize an Option<Duration> in a human friendly form.