Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions assets/neptune-banner.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@

███╗ ██╗███████╗██████╗ ████████╗██╗ ██╗███╗ ██╗███████╗
████╗ ██║██╔════╝██╔══██╗╚══██╔══╝██║ ██║████╗ ██║██╔════╝
██╔██╗ ██║█████╗ ██████╔╝ ██║ ██║ ██║██╔██╗ ██║█████╗
██║╚██╗██║██╔══╝ ██╔═══╝ ██║ ██║ ██║██║╚██╗██║██╔══╝
██║ ╚████║███████╗██║ ██║ ╚██████╔╝██║ ╚████║███████╗
╚═╝ ╚═══╝╚══════╝╚═╝ ╚═╝ ╚═════╝ ╚═╝ ╚═══╝╚══════╝

1 change: 1 addition & 0 deletions neptune-core/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,7 @@ sysinfo = "0.31.4"
thread-priority = "1.2.0"
rayon = "1.10"
humantime = "2.1.0"
owo-colors = "4.2.2"

[dev-dependencies]

Expand Down
7 changes: 7 additions & 0 deletions neptune-core/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ use config_models::cli_args;
use futures::future;
use futures::Future;
use futures::StreamExt;
use owo_colors::OwoColorize;
use models::blockchain::block::Block;
use models::blockchain::shared::Hash;
use models::peer::handshake_data::HandshakeData;
Expand Down Expand Up @@ -105,6 +106,12 @@ const MINER_CHANNEL_CAPACITY: usize = 10;
const RPC_CHANNEL_CAPACITY: usize = 1000;
const VERSION: &str = env!("CARGO_PKG_VERSION");

pub const NEPTUNE_BANNER: &str = include_str!("../../assets/neptune-banner.txt");

pub fn display_banner() {
println!("{}", NEPTUNE_BANNER.fg_rgb::<255, 255, 255>().bold());
}

/// Causes compilation failures on targets where `u32` does not fit within a
/// `usize`.
const _MIN_PTR_WIDTH: () = {
Expand Down
2 changes: 2 additions & 0 deletions neptune-core/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,10 @@ use clap::Parser;
use neptune_cash::config_models::cli_args;
use tracing_subscriber::EnvFilter;
use tracing_subscriber::FmtSubscriber;
use neptune_cash::display_banner;

pub fn main() -> Result<()> {
display_banner();
let tokio_runtime = tokio::runtime::Builder::new_multi_thread()
.enable_io()
.enable_time()
Expand Down
2 changes: 2 additions & 0 deletions neptune-dashboard/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ use dashboard_app::Config;
use dashboard_app::DashboardApp;
use neptune_cash::config_models::data_directory::DataDirectory;
use neptune_cash::rpc_auth;
use neptune_cash::display_banner;
use neptune_cash::rpc_server::error::RpcError;
use neptune_cash::rpc_server::RPCClient;
use tarpc::client;
Expand All @@ -28,6 +29,7 @@ use tarpc::tokio_serde::formats::Json;

#[tokio::main]
async fn main() {
display_banner();
// we set this panic hook so we can drop out of raw mode in order to
// display the panic message. else there is wicked screen corruption.
set_panic_hook();
Expand Down
Loading