Skip to content

Commit

Permalink
Version bump
Browse files Browse the repository at this point in the history
  • Loading branch information
oli-obk committed Mar 19, 2018
1 parent 4edd140 commit 47a7066
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 7 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
# Change Log
All notable changes to this project will be documented in this file.

## 0.0.189
* Rustup to *rustc 1.26.0-nightly (5508b2714 2018-03-18)*

## 0.0.188
* Rustup to *rustc 1.26.0-nightly (392645394 2018-03-15)*
* New lint: [`while_immutable_condition`]
Expand Down
4 changes: 2 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "clippy"
version = "0.0.188"
version = "0.0.189"
authors = [
"Manish Goregaokar <[email protected]>",
"Andre Bogus <[email protected]>",
Expand Down Expand Up @@ -37,7 +37,7 @@ path = "src/driver.rs"

[dependencies]
# begin automatic update
clippy_lints = { version = "0.0.188", path = "clippy_lints" }
clippy_lints = { version = "0.0.189", path = "clippy_lints" }
# end automatic update
cargo_metadata = "0.5"
regex = "0.2"
Expand Down
2 changes: 1 addition & 1 deletion clippy_lints/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[package]
name = "clippy_lints"
# begin automatic update
version = "0.0.188"
version = "0.0.189"
# end automatic update
authors = [
"Manish Goregaokar <[email protected]>",
Expand Down
16 changes: 12 additions & 4 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -59,10 +59,18 @@ pub fn main() {
return;
}

let manifest_path_arg = std::env::args()
let mut manifest_path_arg = std::env::args()
.skip(2)
.find(|val| val.starts_with("--manifest-path="))
.map(|val| val["--manifest-path=".len()..].to_owned());
.skip_while(|val| !val.starts_with("--manifest-path"));
let manifest_path_arg = manifest_path_arg.next().and_then(|val| {
if val == "--manifest-path" {
manifest_path_arg.next()
} else if val.starts_with("--manifest-path=") {
Some(val["--manifest-path=".len()..].to_owned())
} else {
None
}
});

let mut metadata = if let Ok(metadata) = cargo_metadata::metadata(manifest_path_arg.as_ref().map(AsRef::as_ref)) {
metadata
Expand Down Expand Up @@ -140,7 +148,7 @@ pub fn main() {

for target in package.targets {
let args = std::env::args()
.skip(2)
.skip(1)
.filter(|a| a != "--all" && !a.starts_with("--manifest-path="));

let args = std::iter::once(format!("--manifest-path={}", manifest_path)).chain(args);
Expand Down

0 comments on commit 47a7066

Please sign in to comment.