greentic-runner-host 1.1.2

Host runtime shim for Greentic runner: config, pack loading, activity handling
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
use std::path::Path;

use anyhow::{Result, bail};
use tokio::fs;

pub async fn verify_pack(path: &Path) -> Result<()> {
    let metadata = fs::metadata(path).await?;
    if !metadata.is_file() {
        bail!("pack path {path:?} is not a file");
    }
    Ok(())
}