You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: init.rs
    path of file: ./repos/wasmer/lib/cli/src/commands
    
    the code of the file until where you have to start completion: use std::{
    collections::HashMap,
    path::{Path, PathBuf},
};

use anyhow::Context;
use cargo_metadata::{CargoOpt, MetadataCommand};
use clap::Parser;
use semver::VersionReq;
use wasmer_registry::wasmer_env::WasmerEnv;

static NOTE: &str = "# See more keys and definitions at https://docs.wasmer.io/registry/manifest";

const NEWLINE: &str = if cfg!(windows) { "\r\n" } else { "\n" };

/// CLI args for the `wasmer init` command
#[derive(Debug, Parser)]
pub struct Init {
    #[clap(flatten)]
    env: WasmerEnv,

    /// Initialize wasmer.toml for a library package
    #[clap(long, group = "crate-type")]
    pub lib: bool,
  
    
fn parse_cargo_toml(manifest_path: &PathBuf) -> Result<MiniCargoTomlPackage, anyhow::Error> {
    let mut metadata = MetadataCommand::new();
    metadata.manifest_path(manifest_path);
    metadata.no_deps();
    metadata.features(CargoOpt::AllFeatures);

    let metadata = metadata.exec().with_context(|| {
        format!(
            "Unable to load metadata from \"{}\"",
            manifest_path.display()
        )
    })?;

    let package = metadata
        .root_package()
        .ok_or_else(|| anyhow::anyhow!("no root package found in cargo metadata"))
        .context(anyhow::anyhow!("{}", manifest_path.display()))?;

    Ok(MiniCargoTomlPackage {
        cargo_toml_path: manifest_path.clone(),
        name: package.name.clone(),
        version: package.version.clone(),
        description: package.description.clone(),
        homepage: package.homepage.clone(),
        repository: package.repository.clone(),
        license: package.license.clone(),
        readme: package.readme.clone().map(|s| s.into_std_path_buf()),
        license_file: package.license_file.clone().map(|f| f.into_std_path_buf()),
        workspace_root: metadata.workspace_root.into_std_path_buf(),
        build_dir: metadata
            .target_directory
            .into_std_path_buf()
            .join("wasm32-wasi"),
    })
}