From 7805a6d684cf2112875a3bcecdd3377eb0536b0f Mon Sep 17 00:00:00 2001 From: Franck Royer Date: Thu, 11 Feb 2021 09:59:24 +1100 Subject: [PATCH] Move cli specific modules under cli folder nectar will also have its own folder with a separate config. --- swap/src/bin/cli.rs | 8 +++++--- swap/src/cli.rs | 2 ++ swap/src/{ => cli}/command.rs | 0 swap/src/{ => cli}/config.rs | 0 swap/src/lib.rs | 3 +-- 5 files changed, 8 insertions(+), 5 deletions(-) create mode 100644 swap/src/cli.rs rename swap/src/{ => cli}/command.rs (100%) rename swap/src/{ => cli}/config.rs (100%) diff --git a/swap/src/bin/cli.rs b/swap/src/bin/cli.rs index 5def8d61..4d8950cb 100644 --- a/swap/src/bin/cli.rs +++ b/swap/src/bin/cli.rs @@ -19,9 +19,11 @@ use std::{path::PathBuf, sync::Arc}; use structopt::StructOpt; use swap::{ bitcoin, - command::{Arguments, Cancel, Command, Refund, Resume}, - config::{ - initial_setup, query_user_for_initial_testnet_config, read_config, ConfigNotInitialized, + cli::{ + command::{Arguments, Cancel, Command, Refund, Resume}, + config::{ + initial_setup, query_user_for_initial_testnet_config, read_config, ConfigNotInitialized, + }, }, database::Database, execution_params, diff --git a/swap/src/cli.rs b/swap/src/cli.rs new file mode 100644 index 00000000..6d982acc --- /dev/null +++ b/swap/src/cli.rs @@ -0,0 +1,2 @@ +pub mod command; +pub mod config; diff --git a/swap/src/command.rs b/swap/src/cli/command.rs similarity index 100% rename from swap/src/command.rs rename to swap/src/cli/command.rs diff --git a/swap/src/config.rs b/swap/src/cli/config.rs similarity index 100% rename from swap/src/config.rs rename to swap/src/cli/config.rs diff --git a/swap/src/lib.rs b/swap/src/lib.rs index 3dd85f26..b23fe07c 100644 --- a/swap/src/lib.rs +++ b/swap/src/lib.rs @@ -17,8 +17,7 @@ )] pub mod bitcoin; -pub mod command; -pub mod config; +pub mod cli; pub mod database; pub mod execution_params; pub mod fs;