A few missing emojies (#5490)

* A few missing emojies

* P2p message emojis

* Add a bit of colour

* format

* Introduce a couple of spaces

* Some spaces
This commit is contained in:
Gavin Wood
2020-04-01 19:41:48 +02:00
committed by GitHub
parent 84ff6ef157
commit b86c7e87a9
8 changed files with 32 additions and 31 deletions
+5 -5
View File
@@ -76,16 +76,16 @@ impl<B: BlockT> InformantDisplay<B> {
if self.format == OutputFormat::Coloured {
info!(
target: "substrate",
"{}{} ({} peers), best: #{} ({}), finalized #{} ({}), ⬇ {} ⬆ {}",
"{}{} ({} peers), best: #{} ({}), finalized #{} ({}), {} {}",
Colour::White.bold().paint(&status),
target,
Colour::White.bold().paint(format!("{}", num_connected_peers)),
Colour::White.paint(format!("{}", best_number)),
Colour::White.bold().paint(format!("{}", best_number)),
best_hash,
Colour::White.paint(format!("{}", finalized_number)),
Colour::White.bold().paint(format!("{}", finalized_number)),
info.chain.finalized_hash,
TransferRateFormat(net_status.average_download_per_sec),
TransferRateFormat(net_status.average_upload_per_sec),
Colour::Green.paint(format!("{}", TransferRateFormat(net_status.average_download_per_sec))),
Colour::Red.paint(format!("{}", TransferRateFormat(net_status.average_upload_per_sec))),
);
} else {
info!(
+6 -5
View File
@@ -16,6 +16,7 @@
//! Console informant. Prints sync progress and block events. Runs on the calling thread.
use ansi_term::Colour;
use sc_client_api::BlockchainEvents;
use futures::prelude::*;
use log::{info, warn, trace};
@@ -79,10 +80,10 @@ pub fn build(service: &impl AbstractService, format: OutputFormat) -> impl futur
match maybe_ancestor {
Ok(ref ancestor) if ancestor.hash != *last_hash => info!(
"♻️ Reorg from #{},{} to #{},{}, common ancestor #{},{}",
last_num, last_hash,
n.header.number(), n.hash,
ancestor.number, ancestor.hash,
"♻️ Reorg on #{},{} to #{},{}, common ancestor #{},{}",
Colour::Red.bold().paint(format!("{}", last_num)), last_hash,
Colour::Green.bold().paint(format!("{}", n.header.number())), n.hash,
Colour::White.bold().paint(format!("{}", ancestor.number)), ancestor.hash,
),
Ok(_) => {},
Err(e) => warn!("Error computing tree route: {}", e),
@@ -94,7 +95,7 @@ pub fn build(service: &impl AbstractService, format: OutputFormat) -> impl futur
last_best = Some((n.header.number().clone(), n.hash.clone()));
}
info!(target: "substrate", "✨ Imported #{} ({})", n.header.number(), n.hash);
info!(target: "substrate", "✨ Imported #{} ({})", Colour::White.bold().paint(format!("{}", n.header.number())), n.hash);
future::ready(())
});