fn bump_own_version_prerelease(name: &str, path: &str) -> Version {
    let manifest_path = format!("{}/Cargo.toml", path);
    let cargo_manifest_str = std::fs::read_to_string(&manifest_path).unwrap();
    let mut cargo_manifest = cargo_manifest_str.parse::<toml_edit::Document>().unwrap();
    let version = cargo_manifest["package"]["version"].as_str().unwrap();
    log::info!("  => Found name={} version={}", name, version);

    let sem_version = Version::parse(version).unwrap();
    let next_version = prerelease_bump(sem_version);

    cargo_manifest["package"]["version"] = value_from_version(&next_version);
    let cargo_manifest_str = cargo_manifest.to_string();
    std::fs::write(&manifest_path, cargo_manifest_str).unwrap();

    next_version
}
/// Modify version field in a certain manifest to be bumped to the next pre-release major version
Modify version field in a certain manifest to be bumped to the next pre-release major version
Modify version field in a certain manifest to be bumped to the next pre - release major version
fn bump_own_version_prerelease(name: &str, path: &str) -> Version {
    let manifest_path = format!("{}/Cargo.toml", path);
    let cargo_manifest_str = std::fs::read_to_string(&manifest_path).unwrap();
    let mut cargo_manifest = cargo_manifest_str.parse::<toml_edit::Document>().unwrap();
    let version = cargo_manifest["package"]["version"].as_str().unwrap();
    log::info!("  => Found name={} version={}", name, version);
    let sem_version = Version::parse(version).unwrap();
    let next_version = prerelease_bump(sem_version);
    cargo_manifest["package"]["version"] = value_from_version(&next_version);
    let cargo_manifest_str = cargo_manifest.to_string();
    std::fs::write(&manifest_path, cargo_manifest_str).unwrap();
    next_version
}
fn bump_own_version_prerelease ( name : & str , path : & str ) -> Version { let manifest_path = format ! ( " " path ) ; let cargo_manifest_str = std :: fs :: read_to_string ( & manifest_path ) . unwrap ( ) ; let mut cargo_manifest = cargo_manifest_str . parse :: < toml_edit :: Document > ( ) . unwrap ( ) ; let version = cargo_manifest [ " " ] [ " " ] . as_str ( ) . unwrap ( ) ; log :: info ! ( " " name version ) ; let sem_version = Version :: parse ( version ) . unwrap ( ) ; let next_version = prerelease_bump ( sem_version ) ; cargo_manifest [ " " ] [ " " ] = value_from_version ( & next_version ) ; let cargo_manifest_str = cargo_manifest . to_string ( ) ; std :: fs :: write ( & manifest_path , cargo_manifest_str ) . unwrap ( ) ; next_version }
Modify version field in a certain manifest to be bumped to the next pre-release major version
Modify version field in a certain manifest to be bumped to the next pre - release major version
name
&str
path
&str
name
&str
path
&str