Add clippy

This commit is contained in:
Danilo Bargen 2016-01-14 09:03:18 +01:00
commit e00fe75d37
3 changed files with 41 additions and 1 deletions

28
Cargo.lock generated
View file

@ -3,6 +3,7 @@ name = "tldr"
version = "0.1.0"
dependencies = [
"ansi_term 0.7.1 (registry+https://github.com/rust-lang/crates.io-index)",
"clippy 0.0.37 (registry+https://github.com/rust-lang/crates.io-index)",
"curl 0.2.15 (registry+https://github.com/rust-lang/crates.io-index)",
"docopt 0.6.78 (registry+https://github.com/rust-lang/crates.io-index)",
"env_logger 0.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
@ -36,6 +37,15 @@ name = "ansi_term"
version = "0.7.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
[[package]]
name = "clippy"
version = "0.0.37"
source = "registry+https://github.com/rust-lang/crates.io-index"
dependencies = [
"semver 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
"unicode-normalization 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
]
[[package]]
name = "curl"
version = "0.2.15"
@ -177,6 +187,11 @@ dependencies = [
"libc 0.2.4 (registry+https://github.com/rust-lang/crates.io-index)",
]
[[package]]
name = "nom"
version = "1.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
[[package]]
name = "openssl-sys"
version = "0.7.4"
@ -232,6 +247,14 @@ name = "rustc-serialize"
version = "0.3.16"
source = "registry+https://github.com/rust-lang/crates.io-index"
[[package]]
name = "semver"
version = "0.2.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
dependencies = [
"nom 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
]
[[package]]
name = "strsim"
version = "0.3.0"
@ -265,6 +288,11 @@ dependencies = [
"winapi 0.2.5 (registry+https://github.com/rust-lang/crates.io-index)",
]
[[package]]
name = "unicode-normalization"
version = "0.1.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
[[package]]
name = "url"
version = "0.2.38"

View file

@ -2,10 +2,15 @@
name = "tldr"
version = "0.1.0"
authors = ["Danilo Bargen <mail@dbrgn.ch>"]
repository = "https://github.com/dbrgn/tldr-rs/"
homepage = "https://github.com/dbrgn/tldr-rs/"
license = "MIT/Apache-2.0"
readme = "README.md"
description = "Fetch and show tldr help pages for many CLI commands."
[features]
logging = ["env_logger"]
dev = ["clippy"]
[dependencies]
ansi_term = "^0.7"
@ -13,8 +18,9 @@ log = "^0.3"
tar = { git = "https://github.com/dbrgn/tar-rs", branch = "pax_header" }
flate2 = "^0.2"
curl = "^0.2"
env_logger = { version = "^0.3", optional = true }
rustc-serialize = "^0.3"
docopt = "^0.6"
time = "^0.1"
walkdir = "^0.1"
env_logger = { version = "^0.3", optional = true }
clippy = {version = "0.0.37", optional = true}

View file

@ -15,6 +15,12 @@
missing_copy_implementations,
unused_extern_crates, unused_results)]
#![cfg_attr(feature = "dev", feature(plugin))]
#![cfg_attr(feature = "dev", plugin(clippy))]
#![cfg_attr(feature = "dev", warn(cast_possible_truncation, cast_possible_wrap, cast_precision_loss, cast_sign_loss,
mut_mut, non_ascii_literal, option_unwrap_used, result_unwrap_used,
shadow_reuse, shadow_same, unicode_not_nfc,
wrong_self_convention, wrong_pub_self_convention))]
#[macro_use] extern crate log;
#[cfg(feature = "logging")]extern crate env_logger;