Skip to content
This repository was archived by the owner on Jul 30, 2026. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 17 additions & 3 deletions crates/tokscale-cli/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2916,8 +2916,16 @@ fn run_clients_command(json: bool) -> Result<()> {
let clients: Vec<ClientRow> =
ClientId::iter()
.map(|client| {
let sessions_path = client.data().resolve_path(&home_dir.to_string_lossy());
let sessions_path_exists = Path::new(&sessions_path).exists();
let (sessions_path, sessions_path_exists) = if client == ClientId::Amp {
(
tokscale_core::sessions::amp::amp_source_label().to_string(),
tokscale_core::sessions::amp::amp_cli_available(),
)
} else {
let sessions_path = client.data().resolve_path(&home_dir.to_string_lossy());
let sessions_path_exists = Path::new(&sessions_path).exists();
(sessions_path, sessions_path_exists)
};
let additional_paths: Vec<AdditionalPath> = built_in_extra_paths
.iter()
.filter(|(c, _)| *c == client)
Expand Down Expand Up @@ -3059,10 +3067,16 @@ fn run_clients_command(json: bool) -> Result<()> {

for row in clients {
println!(" {}", row.label.white());
let source_label = if row.client == "amp" {
"source"
} else {
"sessions"
};
println!(
" {}",
format!(
"sessions: {}",
"{}: {}",
source_label,
describe_path(&row.sessions_path, row.sessions_path_exists)
)
.bright_black()
Expand Down
8 changes: 5 additions & 3 deletions crates/tokscale-core/src/clients.rs
Original file line number Diff line number Diff line change
Expand Up @@ -215,9 +215,11 @@ define_clients!(
},
Amp = 5 => {
id: "amp",
root: PathRoot::XdgData,
relative: "amp/threads",
pattern: "T-*.json",
// Amp usage is collected through `amp threads list/export`; this path
// is only the local CLI marker used to decide whether Amp is present.
root: PathRoot::Home,
relative: ".local/bin/amp",
pattern: "",
headless: false,
parse_local: true,
submit_default: true
Expand Down
Loading