Skip to content

Commit

Permalink
Merge pull request #64 from kbknapp/issue-57
Browse files Browse the repository at this point in the history
imp: enable --all-features by default
  • Loading branch information
Frederick888 authored Sep 20, 2017
2 parents 220eca1 + f24c3a6 commit 8eac151
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 18 deletions.
2 changes: 0 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,9 +88,7 @@ USAGE:
cargo outdated [FLAGS] [OPTIONS]
FLAGS:
--all-features Check outdated packages with all features enabled
-h, --help Prints help information
--no-default-features Do not include the `default` feature
-R, --root-deps-only Only check root dependencies (Equivalent to --depth=1)
-V, --version Prints version information
-v, --verbose Use verbose output
Expand Down
19 changes: 3 additions & 16 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,7 @@
/// cargo outdated [FLAGS] [OPTIONS]
///
/// FLAGS:
/// --all-features Check outdated packages with all features enabled
/// -h, --help Prints help information
/// --no-default-features Do not include the `default` feature
/// -R, --root-deps-only Only check root dependencies (Equivalent to --depth=1)
/// -V, --version Prints version information
/// -v, --verbose Use verbose output
Expand Down Expand Up @@ -72,8 +70,8 @@ impl Options {
flag_features: m.values_of("features")
.map(|vals| vals.into_iter().map(String::from).collect())
.unwrap_or_default(),
flag_all_features: m.is_present("all-features"),
flag_no_default_features: m.is_present("no-default-features"),
flag_all_features: !m.is_present("features"),
flag_no_default_features: false,
flag_manifest_path: m.value_of("manifest-path").map(String::from),
flag_quiet: None,
flag_verbose: m.occurrences_of("verbose") as u32,
Expand Down Expand Up @@ -137,20 +135,9 @@ fn main() {
.takes_value(true)
.value_name("FEATURE")
.value_delimiter(" ")
.empty_values(true)
.conflicts_with_all(&["all-features", "no-default-features"]),
)
.arg(
Arg::with_name("all-features")
.long("all-features")
.help("Check outdated packages with all features enabled")
.conflicts_with_all(&["features", "no-default-features"]),
)
.arg(
Arg::with_name("no-default-features")
.long("no-default-features")
.help("Do not include the `default` feature")
.conflicts_with_all(&["features", "all-features"]),
)
.arg(
Arg::with_name("packages")
.long("packages")
Expand Down

0 comments on commit 8eac151

Please sign in to comment.