@@ -7,44 +7,47 @@ pub struct CliArgs {
77 #[ clap( subcommand) ]
88 pub cmd : Command ,
99 #[ clap( short, long, default_value = "protofetch.toml" ) ]
10- ///location of the protofetch configuration toml
10+ /// location of the protofetch configuration toml
1111 pub module_location : String ,
1212 #[ clap( short, long, default_value = "protofetch.lock" ) ]
13- ///location of the protofetch lock file
13+ /// location of the protofetch lock file
1414 pub lockfile_location : String ,
1515 #[ clap( short, long, default_value = ".protofetch_cache" ) ]
16- ///location of the protofetch cache directory
16+ /// location of the protofetch cache directory
1717 pub cache_directory : String ,
18+ /// name of the proto source files directory output,
19+ /// this will be used if config is not present in the toml config
20+ #[ clap( short, long, default_value = "proto_src" ) ]
21+ pub proto_output_directory : String ,
1822}
1923
2024#[ derive( Debug , Parser ) ]
2125pub enum Command {
22- ///Fetches protodep dependencies defined in the toml configuration file
26+ /// Fetches protodep dependencies defined in the toml configuration file
2327 Fetch {
2428 #[ clap( short, long) ]
2529 ///forces re-creation of lock file
2630 force_lock : bool ,
2731 ///Name of the dependencies source files directory
2832 #[ clap( short, long, default_value = "dependencies" ) ]
2933 source_output_directory : String ,
30- ///Name of the proto files directory
31- #[ clap( short, long, default_value = "proto_src" ) ]
32- proto_output_directory : String ,
3334 } ,
34- ///Creates a lock file based on toml configuration file
35+ /// Creates a lock file based on toml configuration file
3536 Lock ,
36- ///Creates an init protofetch setup in provided directory and name
37+ /// Creates an init protofetch setup in provided directory and name
3738 Init {
3839 #[ clap( default_value = "." ) ]
3940 directory : String ,
4041 #[ clap( short, long) ]
4142 name : Option < String > ,
4243 } ,
43- ///Migrates a protodep toml file to a protofetch format
44+ /// Migrates a protodep toml file to a protofetch format
4445 Migrate {
4546 #[ clap( default_value = "." ) ]
4647 directory : String ,
4748 #[ clap( short, long) ]
4849 name : Option < String > ,
4950 } ,
51+ /// Cleans generated proto sources and lock file
52+ Clean ,
5053}
0 commit comments