fix: Resolve filter parsing and default directory errors

Co-authored-by: aider (openai/andrew/openrouter/sonoma-sky-alpha) <aider@aider.chat>
This commit is contained in:
Andrew Phillips
2025-09-10 16:15:51 -03:00
parent 9bade07938
commit 71fa20ebb3
3 changed files with 17 additions and 8 deletions

View File

@@ -395,6 +395,15 @@ impl Settings {
}
}
pub fn default_dir() -> anyhow::Result<PathBuf> {
let mut path = dirs::home_dir()
.ok_or_else(|| anyhow::anyhow!("No home directory found"))?;
path.push(".keep");
if !path.exists() {
std::fs::create_dir_all(&path)?;
}
Ok(path)
}
/// Get server password from password_file or directly from config if configured
pub fn get_server_password(&self) -> Result<Option<String>> {