MCPcopy Create free account
hub / github.com/GCWing/BitFun / ssh_list_saved_connections

Function ssh_list_saved_connections

src/apps/desktop/src/api/ssh_api.rs:25–44  ·  view source on GitHub ↗
(
    state: State<'_, AppState>,
)

Source from the content-addressed store, hash-verified

23
24#[tauri::command]
25pub async fn ssh_list_saved_connections(
26 state: State<'_, AppState>,
27) -> Result<Vec<SavedConnection>, String> {
28 let manager = state.get_ssh_manager_async().await?;
29 let connections = manager.get_saved_connections().await;
30 log::info!(
31 "ssh_list_saved_connections returning {} connections",
32 connections.len()
33 );
34 for conn in &connections {
35 log::info!(
36 " - id={}, name={}, host={}:{}",
37 conn.id,
38 conn.name,
39 conn.host,
40 conn.port
41 );
42 }
43 Ok(connections)
44}
45
46#[tauri::command]
47pub async fn ssh_save_connection(

Callers

nothing calls this directly

Calls 2

get_ssh_manager_asyncMethod · 0.80
get_saved_connectionsMethod · 0.45

Tested by

no test coverage detected