Skip to content

Commit c9351e6

Browse files
committed
Use updated settings path
1 parent 670bb5d commit c9351e6

File tree

2 files changed

+6
-13
lines changed

2 files changed

+6
-13
lines changed

crates/chat-cli/src/database/settings.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -197,7 +197,7 @@ impl Settings {
197197
return Ok(Self::default());
198198
}
199199

200-
let path = GlobalPaths::settings_path_static()?;
200+
let path = GlobalPaths::settings_path()?;
201201

202202
// If the folder doesn't exist, create it.
203203
if let Some(parent) = path.parent() {
@@ -261,7 +261,7 @@ impl Settings {
261261
return Ok(());
262262
}
263263

264-
let path = GlobalPaths::settings_path_static()?;
264+
let path = GlobalPaths::settings_path()?;
265265

266266
// If the folder doesn't exist, create it.
267267
if let Some(parent) = path.parent() {

crates/chat-cli/src/util/paths.rs

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -404,24 +404,17 @@ impl<'a> GlobalPaths<'a> {
404404
}
405405

406406
pub fn settings_path() -> Result<PathBuf> {
407-
Ok(dirs::data_local_dir()
407+
Ok(dirs::home_dir()
408408
.ok_or(DirectoryError::NoHomeDirectory)?
409-
.join("amazon-q")
410-
.join("settings.json"))
409+
.join(".kiro")
410+
.join("settings")
411+
.join("cli.json"))
411412
}
412413

413414
pub fn mcp_auth_dir(&self) -> Result<PathBuf> {
414415
Ok(home_dir(self.os)?.join(".aws").join("sso").join("cache"))
415416
}
416417

417-
/// Static method for settings path that doesn't require Os (to avoid circular dependency)
418-
pub fn settings_path_static() -> Result<PathBuf> {
419-
Ok(dirs::data_local_dir()
420-
.ok_or(DirectoryError::NoHomeDirectory)?
421-
.join("amazon-q")
422-
.join("settings.json"))
423-
}
424-
425418
/// Static method for database path that doesn't require Os (to avoid circular dependency)
426419
pub fn database_path_static() -> Result<PathBuf> {
427420
Ok(dirs::data_local_dir()

0 commit comments

Comments
 (0)