1 use std::fs::create_dir_all;
2 use std::io::{Result, Error};
3 use crate::configuration::Configuration;
13 impl super::Command for SyncDown {
14 fn before_dependencies(&self) -> Vec<Box<dyn super::Command>> {
18 fn execute(&self, _: Option<&String>, configuration: &Configuration, command: &String) -> Result<()> {
19 match create_dir_all(&configuration.data_directory) {
21 // We only care to show these warnings if this is the primary command.
22 if command == self.command() {
23 println!("WARNING: Sync Down Not yet implemented");
27 Err(e) => Err(Error::new(e.kind(), format!("Could not create data directory")))
31 fn after_dependencies(&self) -> Vec<Box<dyn super::Command>> {
35 fn command(&self) -> &'static str {
39 fn help(&self) -> &'static str {
40 "\t\t\t\tPulls from the git remote if configured"