Function cargo_edit_9::get_latest_dependency
source · pub fn get_latest_dependency(
crate_name: &str,
flag_allow_prerelease: bool,
manifest_path: &Path,
registry: Option<&Url>
) -> CargoResult<Dependency>
Expand description
Query latest version from a registry index
The registry argument must be specified for crates from alternative registries.
The latest version will be returned as a Dependency
. This will fail, when
- there is no Internet connection and offline is false.
- summaries in registry index with an incorrect format.
- a crate with the given name does not exist on the registry.