refactor(command|utility): rewrite git

This commit is contained in:
Romain J 2019-09-28 01:14:59 +02:00
parent 60f68f245d
commit 3ae55bc92e
6 changed files with 30 additions and 2 deletions

View file

@ -77,5 +77,5 @@
- [ ] ytdiscover
- [x] iplocalise
- [x] getheaders
- [ ] git
- [x] git
- [ ] quote

View file

@ -99,6 +99,21 @@ class Utility(commands.Cog):
await ctx.send(f"{Texts('utility').get('Cannot connect to host')} "
f"{addr}")
"""---------------------------------------------------------------------"""
@commands.command(name='git', aliases=['sources', 'source', 'github'])
async def _git(self, ctx):
e = discord.Embed(
title=Texts('utility').get('git repo'),
description=Texts('utility').get('git text'),
colour=0xE9D460
)
e.set_author(
name='Gnous',
icon_url="https://cdn.gnous.eu/logo1.png"
)
await ctx.send(embed=e)
def setup(bot: TuxBot):
bot.add_cog(Utility(bot))

View file

@ -34,4 +34,11 @@ msgid "Headers of"
msgstr ""
msgid "Cannot connect to host"
msgstr ""
msgstr ""
msgid "git repo"
msgstr "TuxBot-Bot's repository"
msgid "git text"
msgstr "Whoa, do you want to see my Gitea repository to dissect me? No problem ! I am a Bot, I do not feel the pain! \n https://git.gnous.eu/gnouseu/tuxbot-bot"

View file

@ -35,3 +35,9 @@ msgstr "Entêtes de"
msgid "Cannot connect to host"
msgstr "Impossible de se connecter à l'hôte"
msgid "git repo"
msgstr "Repos TuxBot-Bot"
msgid "git text"
msgstr "Whoa tu veux voir mon repos Gitea pour me disséquer ? Pas de soucis ! Je suis un Bot, je ne ressens pas la douleur! \n https://git.gnous.eu/gnouseu/tuxbot-bot"