hm-plugin-cloud 0.0.6

Cloud client library for the hm CLI.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
//! `hm cloud logout` — clears the stored bearer token.

use std::collections::BTreeMap;

use anyhow::Result;

use crate::settings;

pub(crate) async fn run(_env: &BTreeMap<String, String>) -> Result<()> {
    let (_client, api) = settings::anon_client()?;
    hm_config::creds::forget_cloud_token(&api);
    tracing::info!("logged out of {api}");
    Ok(())
}