mirror of
https://github.com/rust-lang/cargo.git
synced 2025-09-25 11:14:46 +00:00
fix(publish): Pluralize the wait message
This commit is contained in:
parent
8c401a2674
commit
ba789f04c7
@ -274,7 +274,8 @@ pub fn publish(ws: &Workspace<'_>, opts: &PublishOpts<'_>) -> CargoResult<()> {
|
||||
let short_pkg_descriptions = package_list(to_confirm.iter().copied(), "or");
|
||||
opts.gctx.shell().note(format!(
|
||||
"waiting for {short_pkg_descriptions} to be available at {source_description}.\n\
|
||||
You may press ctrl-c to skip waiting; the crate should be available shortly."
|
||||
You may press ctrl-c to skip waiting; the {crate} should be available shortly.",
|
||||
crate = if to_confirm.len() == 1 { "crate" } else {"crates"}
|
||||
))?;
|
||||
|
||||
let timeout = Duration::from_secs(timeout);
|
||||
@ -299,10 +300,15 @@ pub fn publish(ws: &Workspace<'_>, opts: &PublishOpts<'_>) -> CargoResult<()> {
|
||||
opts.gctx.shell().warn(format!(
|
||||
"timed out waiting for {short_pkg_descriptions} to be available in {source_description}",
|
||||
))?;
|
||||
opts.gctx.shell().note(
|
||||
opts.gctx.shell().note(format!(
|
||||
"the registry may have a backlog that is delaying making the \
|
||||
crate available. The crate should be available soon.",
|
||||
)?;
|
||||
{crate} available. The {crate} should be available soon.",
|
||||
crate = if to_confirm.len() == 1 {
|
||||
"crate"
|
||||
} else {
|
||||
"crates"
|
||||
}
|
||||
))?;
|
||||
}
|
||||
confirmed
|
||||
} else {
|
||||
|
@ -3890,7 +3890,7 @@ fn workspace_parallel() {
|
||||
[UPLOADED] b v0.0.1 to registry `crates-io`
|
||||
[UPLOADED] a v0.0.1 to registry `crates-io`
|
||||
[NOTE] waiting for `a v0.0.1` or `b v0.0.1` to be available at registry `crates-io`.
|
||||
You may press ctrl-c to skip waiting; the crate should be available shortly.
|
||||
You may press ctrl-c to skip waiting; the crates should be available shortly.
|
||||
[PUBLISHED] a v0.0.1, b v0.0.1 at registry `crates-io`
|
||||
[UPLOADING] c v0.0.1 ([ROOT]/foo/c)
|
||||
[UPLOADED] c v0.0.1 to registry `crates-io`
|
||||
|
Loading…
x
Reference in New Issue
Block a user