pub struct ManifestBuilder { /* private fields */ }Expand description
Builder for Manifest.
Implementations§
Source§impl ManifestBuilder
impl ManifestBuilder
Sourcepub fn name<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
pub fn name<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
The name of the package.
If this is missing, it usually indicates that this package exists only to describe a workspace, similar to Cargo’s notion of a “virtual manifest”.
Sourcepub fn version(&mut self, value: Version) -> &mut Self
pub fn version(&mut self, value: Version) -> &mut Self
The version of the package.
Package managers generally require this to be populated to actually publish the package, but will tolerate its absence during local development.
pub fn description<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
pub fn homepage<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
pub fn license<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
pub fn bugs(&mut self, value: Bugs) -> &mut Self
pub fn keywords(&mut self, value: Vec<String>) -> &mut Self
Sourcepub fn bin(&mut self, value: Bin) -> &mut Self
pub fn bin(&mut self, value: Bin) -> &mut Self
Information about the names and locations of binaries this package provides.
Use crate::BuildManifest::from_manifest to get a normalized version
of this field (and other related fields).
pub fn contributors(&mut self, value: Vec<PersonField>) -> &mut Self
pub fn files(&mut self, value: Option<Vec<String>>) -> &mut Self
pub fn main<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
pub fn man(&mut self, value: Man) -> &mut Self
pub fn directories(&mut self, value: Option<Directories>) -> &mut Self
pub fn module_type<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
pub fn exports(&mut self, value: Exports) -> &mut Self
pub fn imports(&mut self, value: Imports) -> &mut Self
Sourcepub fn repository(&mut self, value: Repository) -> &mut Self
pub fn repository(&mut self, value: Repository) -> &mut Self
Information about the repository this project is hosted in.
Repository::Str can contain many different formats (or plain garbage),
we recommend trying to .parse() it as oro-package-spec’s GitInfo type,
as it understands most of the relevant formats.
Sourcepub fn scripts(&mut self, value: HashMap<String, String>) -> &mut Self
pub fn scripts(&mut self, value: HashMap<String, String>) -> &mut Self
Information about build scripts the package uses.
Use crate::BuildManifest::from_manifest to get a normalized version
of this field (and other related fields).
pub fn config(&mut self, value: Value) -> &mut Self
pub fn engines(&mut self, value: HashMap<String, Range>) -> &mut Self
pub fn os(&mut self, value: Vec<String>) -> &mut Self
pub fn cpu(&mut self, value: Vec<String>) -> &mut Self
pub fn private(&mut self, value: bool) -> &mut Self
pub fn publish_config(&mut self, value: HashMap<String, Value>) -> &mut Self
pub fn dependencies(&mut self, value: IndexMap<String, String>) -> &mut Self
pub fn dev_dependencies(&mut self, value: IndexMap<String, String>) -> &mut Self
pub fn optional_dependencies( &mut self, value: IndexMap<String, String>, ) -> &mut Self
pub fn peer_dependencies( &mut self, value: IndexMap<String, String>, ) -> &mut Self
pub fn bundled_dependencies( &mut self, value: Option<BundledDependencies>, ) -> &mut Self
pub fn workspaces(&mut self, value: Vec<String>) -> &mut Self
pub fn _rest(&mut self, value: HashMap<String, Value>) -> &mut Self
Trait Implementations§
Source§impl Clone for ManifestBuilder
impl Clone for ManifestBuilder
Source§fn clone(&self) -> ManifestBuilder
fn clone(&self) -> ManifestBuilder
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more