tabula rasa

This commit is contained in:
🪞👃🪞 2024-05-23 21:18:56 +03:00
commit 11a9f3ba50
33 changed files with 1937 additions and 0 deletions

41
src/main.rs Normal file
View file

@ -0,0 +1,41 @@
extern crate clap;
extern crate jack;
extern crate crossterm;
use clap::{Parser, Subcommand};
use std::error::Error;
//pub mod sequence;
pub mod engine;
pub mod transport;
pub mod mixer;
pub mod looper;
fn main () -> Result<(), Box<dyn Error>> {
let cli = Cli::parse();
match cli.command {
Command::Transport =>
crate::transport::Transport::run_tui(),
Command::Mixer =>
crate::mixer::Mixer::run_tui(),
Command::Looper =>
crate::looper::Looper::run_tui(),
}
}
#[derive(Debug, Parser)]
#[command(version, about, long_about = None)]
pub struct Cli {
#[command(subcommand)]
command: Command
}
#[derive(Debug, Clone, Subcommand)]
pub enum Command {
/// Control the master transport
Transport,
/// Control the mixer
Mixer,
/// Control the looper
Looper,
}