add source command

This commit is contained in:
Edward Shen 2020-05-01 22:48:39 -04:00
parent ae069154a0
commit d543802181
Signed by: edward
GPG key ID: 19182661E818369F
2 changed files with 16 additions and 2 deletions

View file

@ -1,10 +1,13 @@
use crate::commands::{clap::CLAP_COMMAND, cube::CUBE_COMMAND, heck::HECK_COMMAND}; use crate::commands::{
clap::CLAP_COMMAND, cube::CUBE_COMMAND, heck::HECK_COMMAND, source::SOURCE_COMMAND,
};
use serenity::framework::standard::macros::group; use serenity::framework::standard::macros::group;
mod clap; mod clap;
mod cube; mod cube;
mod heck; mod heck;
mod source;
#[group] #[group]
#[commands(heck, clap, cube)] #[commands(heck, clap, cube, source)]
pub(crate) struct General; pub(crate) struct General;

11
src/commands/source.rs Normal file
View file

@ -0,0 +1,11 @@
use serenity::framework::standard::{macros::command, CommandResult};
use serenity::model::channel::Message;
use serenity::prelude::Context;
#[command]
async fn source(ctx: &mut Context, msg: &Message) -> CommandResult {
msg.channel_id
.say(ctx, "https://git.eddie.sh/edward/discord-kurante")
.await?;
Ok(())
}