zino-cli 0.7.0

CLI tools for zino.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
use clap::Parser;
use zino_cli::{Cli, Subcommands::*};

fn main() {
    let result = match Cli::parse().action() {
        Init(opts) => opts.run(),
        New(opts) => opts.run(),
        Serve(opts) => opts.run(),
        Deploy(opts) => {
            let rt = tokio::runtime::Runtime::new().expect("failed to create tokio runtime");
            rt.block_on(opts.run());
            unreachable!()
        }
    };
    if let Err(err) = result {
        log::error!("fail to run the command: {err}");
    }
}