summaryrefslogtreecommitdiffstats
path: root/examples/imagesearch.rs
blob: e2fd1109e5647dd23cccda4d0d42895da7172324 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
use shiplift::Docker;

#[tokio::main]
async fn main() {
    let docker = Docker::new();
    println!("remote docker images in stock");

    match docker.images().search("rust").await {
        Ok(results) => {
            for result in results {
                println!("{} - {}", result.name, result.description);
            }
        }
        Err(e) => eprintln!("Error: {}", e),
    }
}