2019-05-24 10:25:55 +02:00
|
|
|
// stdlib types
|
|
|
|
pub(crate) use std::{
|
|
|
|
borrow::Cow,
|
|
|
|
cmp::{Ordering, Reverse},
|
|
|
|
collections::{BTreeMap, HashMap},
|
2020-01-05 03:58:42 +01:00
|
|
|
convert::TryInto,
|
2019-05-24 10:25:55 +02:00
|
|
|
env,
|
|
|
|
ffi::{OsStr, OsString},
|
|
|
|
fmt::{self, Display, Formatter},
|
|
|
|
fs::{self, File},
|
|
|
|
hash::Hash,
|
|
|
|
io::{self, Read, Write},
|
|
|
|
path::{Path, PathBuf},
|
|
|
|
process, str,
|
|
|
|
time::{SystemTime, SystemTimeError},
|
2020-01-05 03:58:42 +01:00
|
|
|
usize,
|
2019-05-24 10:25:55 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
// dependencies
|
|
|
|
pub(crate) use libc::EXIT_FAILURE;
|
|
|
|
pub(crate) use regex::{Regex, RegexSet};
|
|
|
|
pub(crate) use serde::{Deserialize, Serialize};
|
|
|
|
pub(crate) use sha1::Sha1;
|
|
|
|
pub(crate) use snafu::{ResultExt, Snafu};
|
2020-01-05 03:58:42 +01:00
|
|
|
pub(crate) use static_assertions::const_assert;
|
2019-05-24 10:25:55 +02:00
|
|
|
pub(crate) use structopt::StructOpt;
|
|
|
|
pub(crate) use url::Url;
|
|
|
|
pub(crate) use walkdir::WalkDir;
|
|
|
|
|
|
|
|
// modules
|
|
|
|
pub(crate) use crate::{bencode, consts, error, torrent};
|
|
|
|
|
|
|
|
// traits
|
2020-01-05 03:58:42 +01:00
|
|
|
pub(crate) use crate::{
|
|
|
|
into_u64::IntoU64, into_usize::IntoUsize, path_ext::PathExt, reckoner::Reckoner,
|
|
|
|
};
|
2019-05-24 10:25:55 +02:00
|
|
|
|
|
|
|
// structs and enums
|
|
|
|
pub(crate) use crate::{
|
2020-01-08 03:05:48 +01:00
|
|
|
env::Env, error::Error, file_info::FileInfo, hasher::Hasher, info::Info, metainfo::Metainfo,
|
|
|
|
mode::Mode, opt::Opt, subcommand::Subcommand, torrent::Torrent,
|
2019-05-24 10:25:55 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
// test modules
|
|
|
|
#[cfg(test)]
|
|
|
|
pub(crate) use crate::testing;
|