mirror of
https://github.com/OMGeeky/google-apis-rs.git
synced 2026-01-06 11:34:34 +01:00
feat(CLI):required arg parsing + first doit() call
We are parsing required scalar values and handle parse-errors correctly, to the point were we make a simple, non-upload doit() call. It shows that we seem to build invalid calls, for now,but that's nothing we can't fix once the time is ripe. Next goals will be related to finalizing the argument parsing code. Fixes #60
This commit is contained in:
@@ -95,12 +95,14 @@ impl fmt::Display for ConfigurationError {
|
||||
#[derive(Debug)]
|
||||
pub enum CLIError {
|
||||
Configuration(ConfigurationError),
|
||||
ParseError(String),
|
||||
}
|
||||
|
||||
impl fmt::Display for CLIError {
|
||||
fn fmt(&self, f: &mut fmt::Formatter) -> Result<(), fmt::Error> {
|
||||
match *self {
|
||||
CLIError::Configuration(ref err) => writeln!(f, "Configuration -> {}", err)
|
||||
CLIError::Configuration(ref err) => writeln!(f, "Configuration -> {}", err),
|
||||
CLIError::ParseError(ref desc) => desc.fmt(f),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user