Struct oro_common::BuildManifest
source · pub struct BuildManifest {
pub bin: HashMap<String, PathBuf>,
pub scripts: HashMap<String, String>,
}Expand description
Manifest intended for use with the build step in orogene’s installer. It
reads and normalizes a package.json’s bins (including the
directories.bin field), and its scripts object.
Fields§
§bin: HashMap<String, PathBuf>Mapping of bin name to the relative path to the script/binary.
scripts: HashMap<String, String>package.json scripts object.
Implementations§
source§impl BuildManifest
impl BuildManifest
sourcepub fn from_path(path: impl AsRef<Path>) -> Result<Self>
pub fn from_path(path: impl AsRef<Path>) -> Result<Self>
Create a new BuildManifest from a given path to a full manifest (package.json),
normalizing its bin field (or its directories.bin) into a plain HashMap.
sourcepub fn from_manifest(manifest: &Manifest) -> Result<Self>
pub fn from_manifest(manifest: &Manifest) -> Result<Self>
Create a new BuildManifest from an already fully loaded Manifest,
normalizing its bin field (or its directories.bin) into a plain HashMap.
Trait Implementations§
source§impl Clone for BuildManifest
impl Clone for BuildManifest
source§fn clone(&self) -> BuildManifest
fn clone(&self) -> BuildManifest
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresource§impl Debug for BuildManifest
impl Debug for BuildManifest
source§impl Default for BuildManifest
impl Default for BuildManifest
source§fn default() -> BuildManifest
fn default() -> BuildManifest
Returns the “default value” for a type. Read more
source§impl<'de> Deserialize<'de> for BuildManifest
impl<'de> Deserialize<'de> for BuildManifest
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl PartialEq<BuildManifest> for BuildManifest
impl PartialEq<BuildManifest> for BuildManifest
source§fn eq(&self, other: &BuildManifest) -> bool
fn eq(&self, other: &BuildManifest) -> bool
This method tests for
self and other values to be equal, and is used
by ==.