mirror of
https://github.com/rust-lang/cargo
synced 2024-10-13 11:12:25 +00:00
fix(pkgid): More consistently refer to SemVer
This commit is contained in:
parent
4238f689f5
commit
c88137cd62
|
@ -15,7 +15,10 @@ impl<'a> ToSemver for &'a str {
|
|||
fn to_semver(self) -> CargoResult<Version> {
|
||||
match Version::parse(self.trim()) {
|
||||
Ok(v) => Ok(v),
|
||||
Err(..) => Err(anyhow::format_err!("cannot parse '{}' as a semver", self)),
|
||||
Err(..) => Err(anyhow::format_err!(
|
||||
"cannot parse '{}' as a SemVer version",
|
||||
self
|
||||
)),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -230,7 +230,7 @@ fn ambiguous_version_no_longer_allowed() {
|
|||
cargo_process("install foo --version=1.0")
|
||||
.with_stderr(
|
||||
"\
|
||||
[ERROR] invalid value '1.0' for '--version <VERSION>': cannot parse '1.0' as a semver
|
||||
[ERROR] invalid value '1.0' for '--version <VERSION>': cannot parse '1.0' as a SemVer version
|
||||
|
||||
tip: if you want to specify SemVer range, add an explicit qualifier, like '^1.0'
|
||||
|
||||
|
|
|
@ -156,7 +156,7 @@ error: invalid package ID specification: `two-ver@0`
|
|||
<tab>Did you mean `two-ver`?
|
||||
|
||||
Caused by:
|
||||
cannot parse '0' as a semver
|
||||
cannot parse '0' as a SemVer version
|
||||
",
|
||||
)
|
||||
.run();
|
||||
|
@ -169,7 +169,7 @@ Caused by:
|
|||
error: invalid package ID specification: `two-ver@0.2`
|
||||
|
||||
Caused by:
|
||||
cannot parse '0.2' as a semver
|
||||
cannot parse '0.2' as a SemVer version
|
||||
",
|
||||
)
|
||||
.run();
|
||||
|
|
Loading…
Reference in a new issue