Remove redundant extern crate imports
This commit is contained in:
parent
65306a30e8
commit
549657df21
8 changed files with 14 additions and 27 deletions
|
@ -289,7 +289,7 @@ impl<'a> Upload<'a> {
|
|||
|
||||
// Prompt the user to continue, quit if the user answered no
|
||||
if !prompt_yes("Continue uploading?", Some(true), &matcher_main) {
|
||||
println!("Upload cancelled");
|
||||
eprintln!("Upload cancelled");
|
||||
quit();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
use std::io::{Error as IoError, Read};
|
||||
use std::path::Path;
|
||||
|
||||
use super::tar::Archive as TarArchive;
|
||||
use tar::Archive as TarArchive;
|
||||
|
||||
pub type Result<T> = ::std::result::Result<T, IoError>;
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@ use std::fs::File;
|
|||
use std::io::{Error as IoError, Write};
|
||||
use std::path::Path;
|
||||
|
||||
use super::tar::Builder as TarBuilder;
|
||||
use tar::Builder as TarBuilder;
|
||||
|
||||
pub type Result<T> = ::std::result::Result<T, IoError>;
|
||||
|
||||
|
|
|
@ -1,4 +1,2 @@
|
|||
extern crate tar;
|
||||
|
||||
pub mod archive;
|
||||
pub mod archiver;
|
||||
|
|
|
@ -1,5 +1,3 @@
|
|||
extern crate directories;
|
||||
|
||||
#[cfg(feature = "infer-command")]
|
||||
use std::ffi::OsString;
|
||||
|
||||
|
|
|
@ -1,16 +1,14 @@
|
|||
extern crate toml;
|
||||
extern crate version_compare;
|
||||
|
||||
use std::fs;
|
||||
use std::io::Error as IoError;
|
||||
use std::path::PathBuf;
|
||||
|
||||
use self::toml::de::Error as DeError;
|
||||
use self::toml::ser::Error as SerError;
|
||||
use self::version_compare::{CompOp, VersionCompare};
|
||||
use failure::Fail;
|
||||
use ffsend_api::file::remote_file::{FileParseError, RemoteFile};
|
||||
use ffsend_api::url::Url;
|
||||
use ffsend_api::{
|
||||
file::remote_file::{FileParseError, RemoteFile},
|
||||
url::Url,
|
||||
};
|
||||
use toml::{de::Error as DeError, ser::Error as SerError};
|
||||
use version_compare::{CompOp, VersionCompare};
|
||||
|
||||
use crate::util::{print_error, print_warning};
|
||||
|
||||
|
|
|
@ -1,10 +1,8 @@
|
|||
extern crate pbr;
|
||||
|
||||
use std::io::{stderr, Stderr};
|
||||
use std::time::Duration;
|
||||
|
||||
use self::pbr::{ProgressBar as Pbr, Units};
|
||||
use ffsend_api::pipe::ProgressReporter;
|
||||
use pbr::{ProgressBar as Pbr, Units};
|
||||
|
||||
/// The refresh rate of the progress bar, in milliseconds.
|
||||
const PROGRESS_BAR_FPS_MILLIS: u64 = 200;
|
||||
|
|
13
src/util.rs
13
src/util.rs
|
@ -1,10 +1,5 @@
|
|||
#[cfg(feature = "clipboard-crate")]
|
||||
extern crate clip;
|
||||
extern crate colored;
|
||||
extern crate directories;
|
||||
extern crate fs2;
|
||||
extern crate open;
|
||||
extern crate regex;
|
||||
#[cfg(feature = "clipboard-bin")]
|
||||
extern crate which;
|
||||
|
||||
|
@ -26,11 +21,10 @@ use std::process::{Command, Stdio};
|
|||
|
||||
#[cfg(feature = "clipboard-crate")]
|
||||
use self::clip::{ClipboardContext, ClipboardProvider};
|
||||
use self::colored::*;
|
||||
#[cfg(feature = "history")]
|
||||
use self::directories::ProjectDirs;
|
||||
use self::fs2::available_space;
|
||||
use chrono::Duration;
|
||||
use colored::*;
|
||||
#[cfg(feature = "history")]
|
||||
use directories::ProjectDirs;
|
||||
use failure::{err_msg, Fail};
|
||||
#[cfg(feature = "clipboard-crate")]
|
||||
use failure::{Compat, Error};
|
||||
|
@ -40,6 +34,7 @@ use ffsend_api::{
|
|||
reqwest,
|
||||
url::Url,
|
||||
};
|
||||
use fs2::available_space;
|
||||
use rand::distributions::Alphanumeric;
|
||||
use rand::{thread_rng, Rng};
|
||||
use regex::Regex;
|
||||
|
|
Loading…
Reference in a new issue