Module stdcli::prelude [] [src]

use stdcli::prelude::*; is considered the standard way to use this library.

This contains the primary modules, traits, structs, and functions so that you can get codding in your cli.

Modules

  • console, dialoguer : contains the Term type and other various types, which allows you to write pretty things to your console/terminal.
  • ctrlc: the main function is ctrlc::set_handler, which allows you to handle ctrlc signals.

Reexports

pub use std_prelude::*;
pub use rayon::prelude::*;
pub use init_log;

Modules

chrono
ctrlc

Cross platform handling of Ctrl-C signals.

fern

Efficient, configurable logging in Rust.

itertools

Itertools — extra iterator adaptors, functions and macros.

libc

Crate docs

rayon

Data-parallelism library that is easy to convert sequential computations into parallel.

regex

This crate provides a library for parsing, compiling, and executing regular expressions. Its syntax is similar to Perl-style regular expressions, but lacks a few features like look around and backreferences. In exchange, all searches execute in linear time with respect to the size of the regular expression and search text.

reqwest
serde
serde_json
serde_yaml

This crate is a Rust library for using the Serde serialization framework with data in YAML file format.

shellexpand

Provides functions for performing shell-like expansions in strings.

tar

A library for reading and writing TAR archives

toml

A TOML-parsing library

walkdir

Crate walkdir provides an efficient and cross platform implementation of recursive directory traversal. Several options are exposed to control iteration, such as whether to follow symbolic links (default off), limit the maximum number of simultaneous open file descriptors and the ability to efficiently skip descending into directories.

Structs

Error

The Error type, which can contain any failure.

Regex

A compiled regular expression for matching Unicode strings.

TempDir

A directory in the filesystem that is automatically deleted when it goes out of scope.

Url

A parsed URL record.

Version

Represents a version number conforming to the semantic versioning scheme.

VersionReq

A VersionReq is a struct containing a list of predicates that can apply to ranges of version numbers. Matching operations can then be done with the VersionReq against a particular version to see if it satisfies some or all of the constraints.

WalkDir

A builder to create an iterator for recursively walking a directory.

Enums

Either

The enum Either with variants Left and Right is a general purpose sum type with two cases.

EitherOrBoth

Value that either holds a single A or B, or both.

Traits

Deserialize

A data structure that can be deserialized from any data format supported by Serde.

Fail

The Fail trait.

Itertools

The trait Itertools: extra iterator adaptors and methods for iterators.

Rand

A type that can be randomly generated using an Rng.

Replacer

Replacer describes types that can be used to replace matches in a string.

ResultExt

Extension methods for Result.

Rng

A random number generator.

SeedableRng

A random number generator that can be explicitly seeded to produce the same stream of randomness multiple times.

Serialize

A data structure that can be serialized into any data format supported by Serde.

StructOpt

A struct that is converted from command line arguments.

Functions

err_msg

Constructs a Fail type from a string.

random

Generates a random value using the thread-local random number generator.

thread_rng

Retrieve the lazily-initialized thread-local random number generator, seeded by the system. Intended to be used in method chaining style, e.g. thread_rng().gen::<i32>().

weak_rng

Create a weak random number generator with a default algorithm and seed.