[−][src]Struct devbox_build::Build
Represents the build itself encaspsulating Cargo environment variables
You start the srcript by creating new Build
instance which provides further access to
project directories and standard Cargo environment variables.
For more info on Cargo environement variables check [Cargo env variables] [Cargo env variables]: https://doc.rust-lang.org/cargo/reference/environment-variables.html
Implementations
impl Build
[src]
pub fn new() -> Self
[src]
Create new Build instance
pub fn current_dir(&self) -> Dir
[src]
Current directory where the build has been run from
impl Build
[src]
Accessors for envionment variables set by Cargo when running the script
pub fn cargo_cmd(&self) -> Cmd
[src]
Cargo executable command
pub fn rustc_cmd(&self) -> Cmd
[src]
Rust compler executable command
pub fn rustc_linker_cmd(&self) -> Cmd
[src]
Rust linker executable command
pub fn rustdoc_cmd(&self) -> Cmd
[src]
Rust doc executable command
pub fn manifest_dir(&self) -> Dir
[src]
Directory containing the project manifest
pub fn manifest_links(&self) -> String
[src]
Project manifest links
value
pub fn out_dir(&self) -> Dir
[src]
Directory in which all output should be placed
pub fn is_release_build(&self) -> bool
[src]
True if cargo profile is release
(run with --release)
pub fn has_feature<P: AsRef<str>>(&self, feature: P) -> bool
[src]
True if care is being build with feature
enabled
pub fn host_triple(&self) -> String
[src]
Achitecure triple of the machine running the build
pub fn target_triple(&self) -> String
[src]
Achitecure triple of the build binaries
pub fn num_jobs(&self) -> u16
[src]
Number of threads to be used by the build
pub fn cfg<P: AsRef<str>>(&self, cfg: P) -> Option<String>
[src]
Return configuration (check Cargo documentation above for more info)
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Build
impl Send for Build
impl Sync for Build
impl Unpin for Build
impl UnwindSafe for Build
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,