1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
use clap::Subcommand;
use std::path::PathBuf;
/// Agent Plugins subcommands
#[derive(Debug, Subcommand, Clone)]
pub enum PluginsSubcommand {
/// List installed Agent Plugins
#[command(name = "list")]
List,
/// Show plugin details
#[command(name = "info")]
Info {
/// Plugin name or path
name: String,
},
/// Validate a plugin directory
#[command(name = "validate")]
Validate {
/// Path to plugin directory
path: PathBuf,
},
/// Install a plugin from a git URL
#[command(name = "add")]
Add {
/// Git URL or local path to plugin
source: String,
/// Plugin name (defaults to directory name)
#[arg(long)]
name: Option<String>,
},
/// Remove an installed plugin
#[command(name = "remove")]
Remove {
/// Plugin name to remove
name: String,
},
}