• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

getdozer / dozer / 4829268814

pending completion
4829268814

Pull #1516

github

GitHub
Merge 845b68ec1 into f2ab0e6ce
Pull Request #1516: Prepare v0.1.19

35090 of 44737 relevant lines covered (78.44%)

11496.87 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/dozer-orchestrator/src/cli/types.rs
1
use clap::{Args, Parser, Subcommand};
2

3
use super::helper::{DESCRIPTION, LOGO};
4

5
#[cfg(feature = "cloud")]
6
use crate::cli::cloud::Cloud;
7
use dozer_types::constants::DEFAULT_CONFIG_PATH;
8

×
9
#[derive(Parser, Debug)]
×
10
#[command(author, version, name = "dozer")]
11
#[command(
12
    about = format!("{} \n {}", LOGO, DESCRIPTION),
13
    long_about = None,
14
)]
15
pub struct Cli {
16
    #[arg(
17
        global = true,
18
        short = 'c',
19
        long,
20
        default_value = DEFAULT_CONFIG_PATH
21
    )]
×
22
    pub config_path: String,
×
23

24
    #[clap(subcommand)]
25
    pub cmd: Option<Commands>,
26
}
27

×
28
#[derive(Debug, Subcommand)]
×
29
pub enum Commands {
30
    #[command(about = "Initialize an app using a template")]
31
    Init,
32
    #[command(about = "Clean home directory")]
33
    Clean,
34
    #[command(
35
        about = "Initialize and lock schema definitions. Once initialized, schemas cannot be changed"
36
    )]
37
    Migrate(Migrate),
38
    #[cfg(feature = "cloud")]
39
    #[command(about = "Deploy cloud applications")]
40
    Cloud(Cloud),
41
    #[command(about = "Run Api Server")]
42
    Api(Api),
43
    #[command(about = "Run App Server")]
44
    App(App),
45
    #[command(about = "Show Sources")]
46
    Connector(Connector),
47
}
48

×
49
#[derive(Debug, Args)]
×
50
#[command(args_conflicts_with_subcommands = true)]
51
pub struct Api {
52
    #[command(subcommand)]
53
    pub command: ApiCommands,
54
}
55

×
56
#[derive(Debug, Args)]
×
57
#[command(args_conflicts_with_subcommands = true)]
58
pub struct Migrate {
59
    #[arg(short = 'f')]
60
    pub force: Option<Option<String>>,
61
}
62

×
63
#[derive(Debug, Args)]
×
64
#[command(args_conflicts_with_subcommands = true)]
65
pub struct Deploy {
×
66
    pub target_url: String,
×
67
    #[arg(short = 'u')]
68
    pub username: Option<String>,
69
    #[arg(short = 'p')]
70
    pub password: Option<String>,
71
}
72

×
73
#[derive(Debug, Args)]
×
74
#[command(args_conflicts_with_subcommands = true)]
75
pub struct App {
×
76
    #[command(subcommand)]
77
    pub command: AppCommands,
78
}
×
79

80
#[derive(Debug, Args)]
×
81
#[command(args_conflicts_with_subcommands = true)]
82
pub struct Connector {
83
    #[command(subcommand)]
84
    pub command: ConnectorCommands,
85
}
×
86

87
#[derive(Debug, Subcommand)]
×
88
pub enum ApiCommands {
89
    Run,
90
    #[command(
91
        author,
92
        version,
×
93
        about = "Generate master token",
94
        long_about = "Master Token can be used to create other run time tokens \
95
        that encapsulate different permissions."
96
    )]
97
    GenerateToken,
98
}
99

100
#[derive(Debug, Subcommand)]
×
101
pub enum AppCommands {
102
    Run,
103
}
104

105
#[derive(Debug, Subcommand)]
×
106
pub enum ConnectorCommands {
107
    Ls,
108
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc