diff --git a/.idea/.gitignore b/.idea/.gitignore new file mode 100644 index 0000000..5c98b42 --- /dev/null +++ b/.idea/.gitignore @@ -0,0 +1,2 @@ +# Default ignored files +/workspace.xml \ No newline at end of file diff --git a/.idea/inspectionProfiles/profiles_settings.xml b/.idea/inspectionProfiles/profiles_settings.xml new file mode 100644 index 0000000..105ce2d --- /dev/null +++ b/.idea/inspectionProfiles/profiles_settings.xml @@ -0,0 +1,6 @@ + + + + \ No newline at end of file diff --git a/.idea/kabot.iml b/.idea/kabot.iml new file mode 100644 index 0000000..6711606 --- /dev/null +++ b/.idea/kabot.iml @@ -0,0 +1,11 @@ + + + + + + + + + + \ No newline at end of file diff --git a/.idea/misc.xml b/.idea/misc.xml new file mode 100644 index 0000000..57741fa --- /dev/null +++ b/.idea/misc.xml @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/.idea/modules.xml b/.idea/modules.xml new file mode 100644 index 0000000..9b257af --- /dev/null +++ b/.idea/modules.xml @@ -0,0 +1,8 @@ + + + + + + + + \ No newline at end of file diff --git a/.idea/vcs.xml b/.idea/vcs.xml new file mode 100644 index 0000000..94a25f7 --- /dev/null +++ b/.idea/vcs.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/kabot/kabot/kabot.py b/kabot/kabot/kabot.py index 865d60c..385a522 100644 --- a/kabot/kabot/kabot.py +++ b/kabot/kabot/kabot.py @@ -72,6 +72,19 @@ class Mybot(commands.Cog): async def clear(self, ctx): self.sounds = [] + @commands.command(help='list des commits') + async def commits(self, ctx, *args): + if args: + args = list(args) + gl = gitlab.Gitlab('https://git.0w.tf/', private_token='VHLsCQTcjF3oxujqFRYz') + gl.auth() + if args[0] == 'list': + projects = gl.projects.list(search='Kabot')[0] + commits = projects.commits.list()[-5:] + await ctx.channel.send(commits) + else: + await ctx.channel.send('unknown command') + @commands.command() async def disconnect(self, ctx): await ctx.guild.voice_client.disconnect()