pub struct ApeOptions {
pub path: Option<OsString>,
pub loader: Option<OsString>,
pub cache_dirs: Vec<PathBuf>,
}Expand description
What a launch plan consults, as the child will see it.
Fields§
§path: Option<OsString>The child’s PATH: locates a bare program name, ape and sh.
loader: Option<OsString>An explicit loader, path or bare name; wins over every other choice.
cache_dirs: Vec<PathBuf>Directories to install an extracted loader in, in order. The first
usable one wins; with none usable a sealed memfd is used (Linux).
Implementations§
Source§impl ApeOptions
impl ApeOptions
Sourcepub fn inherited() -> Self
pub fn inherited() -> Self
The values a child inherits from this process: PATH,
LOADER_ENV, then CACHE_DIR_ENV ahead of the host default
cache directories.
Sourcepub fn with_overrides<'a>(
clear: bool,
overrides: impl IntoIterator<Item = (&'a OsStr, Option<&'a OsStr>)>,
) -> Self
pub fn with_overrides<'a>( clear: bool, overrides: impl IntoIterator<Item = (&'a OsStr, Option<&'a OsStr>)>, ) -> Self
Apply a command’s environment edits over the inherited values; None
removes a variable and clear starts from an empty environment, as
env_clear does. The host default cache directories always follow,
since they do not depend on the child’s environment.
Trait Implementations§
Source§impl Clone for ApeOptions
impl Clone for ApeOptions
Source§impl Debug for ApeOptions
impl Debug for ApeOptions
Source§impl Default for ApeOptions
impl Default for ApeOptions
impl Eq for ApeOptions
Source§impl PartialEq for ApeOptions
impl PartialEq for ApeOptions
impl StructuralPartialEq for ApeOptions
Auto Trait Implementations§
impl Freeze for ApeOptions
impl RefUnwindSafe for ApeOptions
impl Send for ApeOptions
impl Sync for ApeOptions
impl Unpin for ApeOptions
impl UnsafeUnpin for ApeOptions
impl UnwindSafe for ApeOptions
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more