Skip to main content

qualia_cli/cli/
app.rs

1use clap::Subcommand;
2use std::path::PathBuf;
3
4#[derive(Subcommand, Debug, Clone)]
5pub enum AppAction {
6    /// List all installed QApp application packages
7    List {
8        #[arg(long, help = "Optional custom storage path")]
9        storage: Option<PathBuf>,
10    },
11    /// Install or upgrade a QApp from a local directory or unpacked package
12    Install {
13        /// Path to the QApp directory containing qapp.json
14        source: PathBuf,
15        #[arg(long, help = "Optional custom storage path")]
16        storage: Option<PathBuf>,
17        #[arg(long, help = "Require signed content manifest")]
18        production: bool,
19    },
20    /// Cleanly uninstall a QApp package from the registry and disk
21    Uninstall {
22        /// Package ID to uninstall (e.g. org.webizen.poet)
23        package_id: String,
24        #[arg(long, help = "Optional custom storage path")]
25        storage: Option<PathBuf>,
26        #[arg(long, help = "Purge application data directory alongside package")]
27        purge_data: bool,
28    },
29    /// Inspect an installed or local QApp package manifest
30    Info {
31        /// Package ID or path to package directory
32        target: String,
33        #[arg(long, help = "Optional custom storage path")]
34        storage: Option<PathBuf>,
35    },
36    /// Reconcile registry index with existing Qapps directory on disk
37    Reconcile {
38        #[arg(long, help = "Optional custom storage path")]
39        storage: Option<PathBuf>,
40    },
41}