labadoor-csv: Integrate in main cli module
This commit is contained in:
parent
c8e412fa34
commit
58f9eec430
3 changed files with 25 additions and 8 deletions
|
@ -62,11 +62,7 @@ fn auth_user(username: String, resource: String) -> Result<(), ()> {
|
|||
return ret;
|
||||
}
|
||||
|
||||
pub fn csv() {
|
||||
let args: Vec<String> = std::env::args().collect();
|
||||
let method = String::from(&args[1]);
|
||||
let identifier = String::from(&args[2]);
|
||||
let resource_shortcut = args[3].parse::<i8>().unwrap();
|
||||
pub fn csv(path: String, method: String, identifier: String, resource_shortcut: i8) {
|
||||
|
||||
if let Ok(username) = get_username(method, identifier) {
|
||||
if let Ok(resource_name) = get_resource_name(username.clone(), resource_shortcut) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue