use clap::Subcommand;
use crate::db::schema::Access;
pub mod start;
pub mod tokens;
pub mod migrate;
pub mod init;
pub mod buckets;
#[derive(Subcommand, Debug)]
pub enum Commands {
Init,
Start,
#[command(subcommand)]
Tokens(Tokens),
Migrate,
#[command(subcommand)]
Buckets(Buckets),
}
#[derive(Subcommand, Debug)]
pub enum Tokens {
List,
Mint {
name: String,
#[clap(long, value_parser)]
scope: Option<String>,
#[arg(long, short, value_parser)]
access: Option<Access>
},
Revoke {
name: String,
},
}
#[derive(Subcommand, Debug)]
pub enum Buckets {
List,
Create {
name: String,
},
Delete {
name: String
}
}