try to fix paths for windows
This commit is contained in:
parent
005c90adb0
commit
6ac967c6d9
10
src/main.rs
10
src/main.rs
|
@ -23,7 +23,8 @@ fn save_config(config: Config) {
|
|||
let mut config_path = dirs::config_dir()
|
||||
.expect("Couldn't find user config directory");
|
||||
|
||||
config_path.push("ruin/lull");
|
||||
config_path.push("ruin");
|
||||
config_path.push("lull");
|
||||
|
||||
if !config_path.exists() {
|
||||
std::fs::create_dir_all(&config_path)
|
||||
|
@ -46,7 +47,9 @@ fn load_config() -> Option<Config> {
|
|||
let mut config_path = dirs::config_dir()
|
||||
.expect("Couldn't find user config directory");
|
||||
|
||||
config_path.push("ruin/lull/lull.toml");
|
||||
config_path.push("ruin");
|
||||
config_path.push("lull");
|
||||
config_path.push("lull.toml");
|
||||
|
||||
let file = File::open(config_path);
|
||||
|
||||
|
@ -93,7 +96,8 @@ fn error_popup(message: &str) {
|
|||
fn get_data_dir() -> PathBuf {
|
||||
let mut data_dir = dirs::data_dir().expect("Couldn't find user data directory");
|
||||
|
||||
data_dir.push("ruin/lull");
|
||||
data_dir.push("ruin");
|
||||
data_dir.push("lull");
|
||||
|
||||
if !data_dir.exists() {
|
||||
std::fs::create_dir_all(&data_dir).expect("Couldn't create lull data directory");
|
||||
|
|
Loading…
Reference in New Issue