pub struct Selection {
pub disabled: Option<&'static str>,
pub namespace: Namespace,
pub tools: Vec<ToolState>,
}Expand description
What a target gets.
Fields§
§disabled: Option<&'static str>None when caches are on; otherwise why not.
namespace: Namespace§tools: Vec<ToolState>Every tool that applies to the platform, on or off.
Implementations§
Source§impl Selection
impl Selection
Sourcepub fn enabled_tools(&self) -> impl Iterator<Item = &'static CacheTool> + '_
pub fn enabled_tools(&self) -> impl Iterator<Item = &'static CacheTool> + '_
The tools that are on.
Source§impl Selection
impl Selection
Sourcepub fn defer_to_operator(
&mut self,
platform: RunnerPlatform,
is_set: impl Fn(&str) -> bool,
)
pub fn defer_to_operator( &mut self, platform: RunnerPlatform, is_set: impl Fn(&str) -> bool, )
Turns off every tool any of whose variables is_set says somebody
already set: in runner.env, or in the service’s own environment (a
systemd drop-in, the launchd plist, a machine-wide Windows variable).
The whole tool, not the one name: an operator’s RUNNER_TOOL_CACHE
next to this module’s AGENT_TOOLSDIRECTORY would split one tool cache
in two (setup-python prefers the latter), and their
PLAYWRIGHT_BROWSERS_PATH would get a PLAYWRIGHT_SKIP_BROWSER_GC for
a directory nothing prunes.
Trait Implementations§
impl Eq for Selection
impl StructuralPartialEq for Selection
Auto Trait Implementations§
impl Freeze for Selection
impl RefUnwindSafe for Selection
impl Send for Selection
impl Sync for Selection
impl Unpin for Selection
impl UnsafeUnpin for Selection
impl UnwindSafe for Selection
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