Skip to main content

set_state_dir

Function set_state_dir 

Source
pub fn set_state_dir<P>(dir: P)
where P: Into<PathBuf>,
Expand description

Anchor the state tree at dir for the rest of the process, so data/, saves/, and settings resolve under it. Every host installs one before reading project state: the dev CLI its project directory, a shipped application the directory beside its executable (or inside its app bundle), an embedder whatever its own layout implies.