gnostr_asyncgit/gitui/cli/
mod.rs

1use clap::{Parser, Subcommand};
2
3///
4#[derive(Default, Debug, Parser)]
5#[command(name = "gnostr-async")]
6#[command(flatten_help = true)]
7pub struct Args {
8    #[command(subcommand)]
9    ///
10    pub command: Option<Commands>,
11
12    /// Send keys on startup (eg: `gnostr-asyncgit -k ll`).
13    ///     It is possible to send:
14    ///     - single char-keys: a, b, c, ...
15    ///     - special keys: <backspace>, <enter>, <up>, <tab>, <delete>, <esc>, ...
16    ///     - modifiers: <ctrl+a>, <ctrl+shift+alt+a>, <shift+delete>
17    #[clap(short, long, verbatim_doc_comment)]
18    ///
19    pub keys: Option<String>,
20
21    /// Print one frame and exit. Useful for debugging.
22    #[clap(long, action)]
23    ///
24    pub print: bool,
25
26    /// Enable logging to 'gnostr-asyncgit.log'
27    #[clap(long, action)]
28    ///
29    pub log: bool,
30
31    #[clap(long, action)]
32    /// Print version
33    pub version: bool,
34}
35
36///
37#[derive(Debug, Subcommand)]
38pub enum Commands {
39    ///
40    Show {
41        ///
42        reference: String,
43    },
44}