Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump anyhow #72

Merged
merged 1 commit into from
Feb 21, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions cargo-clone-core/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -213,10 +213,10 @@ fn parse_version_req(version: &str) -> CargoResult<String> {

if is_req {
let vers = VersionReq::parse(version)
.with_context(|| format!("Invalid version requirement: `{}`.", version))?;
.with_context(|| format!("Invalid version requirement: `{version}`."))?;
Ok(vers.to_string())
} else {
Ok(format!("={}", version))
Ok(format!("={version}"))
}
}

Expand Down Expand Up @@ -274,10 +274,10 @@ pub fn parse_name_and_version(spec: &str) -> CargoResult<Crate> {
let mut parts = spec.split('@');
let crate_ = parts
.next()
.context(format!("Crate name missing in `{}`.", spec))?;
.context(format!("Crate name missing in `{spec}`."))?;
let version = parts
.next()
.context(format!("Crate version missing in `{}`.", spec))?;
.context(format!("Crate version missing in `{spec}`."))?;

Ok(Crate::new(
crate_.to_owned(),
Expand Down