Expand description
Cross-platform data storage path management for application files.
Provides a unified interface for managing application data storage locations across different operating systems following OS conventions.
§Features
- Platform Support: Windows LocalAppData, macOS Application Support, Linux XDG
- Automatic Directory Creation: Creates required directories on first access
- Permission Handling: Uses locations where users have write permissions
- Environment Variable Support: Respects custom environment overrides
- Fallback Strategy: Uses current directory if standard locations fail
§Usage
use kasl::libs::data_storage::DataStorage;
let storage = DataStorage::new();
let db_path = storage.get_path("kasl.db")?;
let config_path = storage.get_path("config.json")?;Structs§
- Data
Storage - Cross-platform data storage path manager.