MCPcopy Create free account
hub / github.com/PowerShell/DSC / get_default_os_system_root

Function get_default_os_system_root

lib/dsc-lib/src/configure/context.rs:88–92  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

86
87#[cfg(target_os = "windows")]
88fn get_default_os_system_root() -> PathBuf {
89 // use SYSTEMDRIVE env var to get the default target path, append trailing separator
90 let system_drive = std::env::var("SYSTEMDRIVE").unwrap_or_else(|_| "C:".to_string());
91 PathBuf::from(system_drive + "\\")
92}
93
94#[cfg(not(target_os = "windows"))]
95fn get_default_os_system_root() -> PathBuf {

Callers 1

newMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected