MCPcopy Index your code
hub / github.com/NativeScript/SimDeck / metadata_from_launch_agent

Function metadata_from_launch_agent

packages/server/src/main.rs:1969–1994  ·  view source on GitHub ↗
(
    result: service::ServiceInstallResult,
)

Source from the content-addressed store, hash-verified

1967}
1968
1969fn metadata_from_launch_agent(
1970 result: service::ServiceInstallResult,
1971) -> anyhow::Result<ServiceMetadata> {
1972 Ok(ServiceMetadata {
1973 project_root: project_root()?,
1974 pid: 0,
1975 http_url: http_url_for_host("127.0.0.1", result.port),
1976 port: result.port,
1977 bind: IpAddr::V4(Ipv4Addr::LOCALHOST),
1978 advertise_host: result.advertise_host,
1979 client_root: None,
1980 access_token: result
1981 .access_token
1982 .context("SimDeck service did not publish an access token")?,
1983 pairing_code: result.pairing_code,
1984 binary_path: result.executable_path,
1985 started_at: now_secs(),
1986 log_path: Some(result.stdout_log),
1987 video_codec: None,
1988 android_gpu: None,
1989 low_latency: false,
1990 realtime_stream: true,
1991 stream_quality_profile: None,
1992 local_stream_fps: None,
1993 })
1994}
1995
1996#[derive(Clone, Debug, Serialize)]
1997#[serde(rename_all = "camelCase")]

Callers 4

service_statusFunction · 0.85
run_default_serviceFunction · 0.85

Calls 3

project_rootFunction · 0.85
http_url_for_hostFunction · 0.85
now_secsFunction · 0.85

Tested by

no test coverage detected