mirror of
https://github.com/0xrsydn/idx-cli.git
synced 2026-08-07 01:33:52 +00:00
fix: narrow cache miss recovery behavior
This commit is contained in:
parent
018b8aeb55
commit
3533670d92
2 changed files with 12 additions and 8 deletions
|
|
@ -200,7 +200,10 @@ pub fn config_path() -> Result<PathBuf, IdxError> {
|
|||
if let Ok(dir) = std::env::var("XDG_CONFIG_HOME")
|
||||
&& !dir.is_empty()
|
||||
{
|
||||
return Ok(PathBuf::from(dir).join("idx").join("config.toml"));
|
||||
let path = PathBuf::from(dir);
|
||||
if path.is_absolute() {
|
||||
return Ok(path.join("idx").join("config.toml"));
|
||||
}
|
||||
}
|
||||
ProjectDirs::from("", "", "idx")
|
||||
.map(|d| d.config_dir().join("config.toml"))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue