Add version information to stats command

Signed-off-by: trivernis <trivernis@protonmail.com>
pull/2/head
trivernis 3 years ago
parent db2ee9a146
commit a7045ebe5a
Signed by: Trivernis
GPG Key ID: DFFFCC2C7A02DB45

2
Cargo.lock generated

@ -2050,7 +2050,7 @@ checksum = "cda74da7e1a664f795bb1f8a87ec406fb89a02522cf6e50620d016add6dbbf5c"
[[package]]
name = "tobi-rs"
version = "0.1.0"
version = "0.1.1"
dependencies = [
"aspotify",
"chrono",

@ -1,6 +1,6 @@
[package]
name = "tobi-rs"
version = "0.1.0"
version = "0.1.1"
authors = ["trivernis <trivernis@protonmail.com>"]
edition = "2018"

@ -8,6 +8,8 @@ use std::process;
use std::time::{Duration, SystemTime, UNIX_EPOCH};
use sysinfo::{ProcessExt, SystemExt};
const VERSION: &'static str = env!("CARGO_PKG_VERSION");
#[command]
#[description("Shows some statistics about the bot")]
#[usage("")]
@ -30,10 +32,11 @@ async fn stats(ctx: &Context, msg: &Message) -> CommandResult {
let discord_info = format!(
r#"
Version: {}
Owner: <@{}>
Guilds: {}
"#,
bot_info.owner.id, guild_count
VERSION, bot_info.owner.id, guild_count
);
log::trace!("Discord info {}", discord_info);

Loading…
Cancel
Save