pub mod node {
  pub mod node;
  pub use node::*;

  pub mod error;
  pub use error::*;

  pub mod blockchain;
  pub use blockchain::*;
}

pub mod cli;

pub mod args;

pub mod error;

pub mod db {
  pub mod database;
  pub mod error;
  pub use database::*;
  pub use error::*;
}

pub mod bus {
  pub mod event_bus;
  pub mod network;
  pub mod watcher;
  pub mod error;
  pub mod system;

  pub use error::*;
  pub mod executor;
  pub use network::*;
  pub use watcher::*;
  pub use system::*;
}

pub mod executor {
  pub mod executor;
  pub use executor::*;

  pub mod command;
  pub use command::*;
}

pub mod watcher {
  pub mod builder;
  pub mod watcher;

  pub use builder::*;
  pub use watcher::*;

  pub mod command;
  pub use command::*;
}

pub mod protocol {
  pub mod message;
  pub use message::*;

  pub mod connection;
  pub use connection::*;

  pub mod connector;
  pub use connector::*;
}

pub mod seeds_constants;

use cli_renderer::{RenderCommand, RenderTarget};

pub fn log(msg: String) {
  crate::bus::publish_watcher_event(watcher::WatcherCommand::Render(RenderCommand::StringToPaneId {
    pane: RenderTarget::CliOutput,
    str: msg,
  }))
}
