pub fn data_local() -> Option<PathBuf>Expand description
Returns the user’s local data directory (non-roaming).
This is primarily useful on Windows where it returns the local (non-roaming) data directory.
On other platforms, it behaves identically to data_home().
Platform defaults:
- Linux:
~/.local/share(same asdata_home()) - macOS:
~/Library/Application Support(same asdata_home()) - Windows:
%LOCALAPPDATA%(non-roaming)
§Examples
use dir_spec::data_local;
if let Some(data_local) = data_local() {
println!("Local data directory: {}", data_local.display());
}