quick wins (issues #9 #10 #11 #12 #13 #16) : am logs (tail+follow), am list --running/--sort, am config set, am alias add/remove/list, dedup historique, am open
This commit is contained in:
+16
-1
@@ -1,5 +1,6 @@
|
||||
//! Command implementations and dispatch.
|
||||
|
||||
pub mod alias_cmd;
|
||||
pub mod completion_cmd;
|
||||
pub mod config_cmd;
|
||||
pub mod doctor_cmd;
|
||||
@@ -11,6 +12,8 @@ pub mod init_cmd;
|
||||
pub mod install_cmd;
|
||||
pub mod list_cmd;
|
||||
pub mod log_cmd;
|
||||
pub mod logs_cmd;
|
||||
pub mod open_cmd;
|
||||
pub mod run_cmd;
|
||||
pub mod search_cmd;
|
||||
pub mod self_uninstall;
|
||||
@@ -40,7 +43,19 @@ pub fn execute(app: &App) -> Result<i32> {
|
||||
/// Execute one parsed command (also used by the interactive shell).
|
||||
pub fn execute_command(app: &App, cmd: &Command) -> Result<i32> {
|
||||
match cmd {
|
||||
Command::List { all, category } => list_cmd::run(app, *all, category.as_deref()),
|
||||
Command::List {
|
||||
all,
|
||||
category,
|
||||
running,
|
||||
sort,
|
||||
} => list_cmd::run(app, *all, category.as_deref(), *running, sort.as_deref()),
|
||||
Command::Logs {
|
||||
agent,
|
||||
lines,
|
||||
follow,
|
||||
} => logs_cmd::run(app, agent, *lines, *follow),
|
||||
Command::Open { agent } => open_cmd::run(app, agent),
|
||||
Command::Alias(sub) => alias_cmd::run(app, sub),
|
||||
Command::Start(a) => run_cmd::start(app, a),
|
||||
Command::Stop {
|
||||
agent,
|
||||
|
||||
Reference in New Issue
Block a user