Merge pull request #2 from Trivernis/develop

Add version information to stats command
pull/16/head
Trivernis 3 years ago committed by GitHub
commit ad4f825e69
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

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